Newsgroups: comp.lang.postscript
Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!clarkson!grape.ecs.clarkson.edu!nelson
From: nelson@sun.soe.clarkson.edu (Russ Nelson)
Subject: Re: String Concatination
Reply-To: nelson@clutx.clarkson.edu (aka NELSON@CLUTX.BITNET)
Organization: Clarkson University, Potsdam NY
Date: 12 May 91 19:33:06
Message-ID: <NELSON.91May12193306@sun.clarkson.edu>
In-Reply-To: mikec@wam.umd.edu's message of 12 May 91 22:39:39 GMT
References: <1991May12.223939.14987@wam.umd.edu>
Sender: usenet@grape.ecs.clarkson.edu



%% string1 string2 append string
% appends two strings
/append {
	2 copy length exch length add	% find the length of the new.
	string dup
% string1 string2 string string
	4 2 roll
% string string string1 string2
	2 index 0 3 index
% string string string1 string2 string 0 string1
	putinterval	% stuff the first string in.
% string string string1 string2
	exch length exch putinterval
} bind def
--
--russ <nelson@clutx.clarkson.edu> I'm proud to be a humble Quaker.
Clear cutting is criminal, spiking trees is criminal, and using hyperbole of
this magnitude in a serious discussion is criminal.  -- Irv Chidsey
