Path: news.cs.au.dk!not-for-mail From: "Sascha Kimmel" Newsgroups: comp.lang.beta Subject: RE: I feel a bit discriminated Date: 21 Jun 2000 08:31:09 -0000 Organization: University of Aarhus, Department of Computer Science (DAIMI) Lines: 53 Approved: mailtonews@cs.au.dk Distribution: world Message-ID: <20000621083109.10821.qmail@noatun.mjolner.dk> Reply-To: "Sascha Kimmel" NNTP-Posting-Host: daimi.cs.au.dk X-Trace: xinwen.cs.au.dk 961576957 353223 255.255.255.255 (21 Jun 2000 08:42:37 GMT) X-Complaints-To: news@cs.au.dk NNTP-Posting-Date: 21 Jun 2000 08:42:37 GMT Xref: news.cs.au.dk comp.lang.beta:12476 > -----Original Message----- > From: Peter von der Ahé [mailto:nospam2159@cs.au.dk] > Sent: Monday, June 19, 2000 7:04 PM > To: usergroup@mjolner.dk > Subject: Re: I feel a bit discriminated > > > >>>>> "SK" == Sascha Kimmel writes: > > SK> In BETA it is IMPOSSIBLE to concatenate strings as in the most > > [...] > > SK> In BETA you would need to do this the follwing way: > > [...] > > SK> thisstring[]->string.append; > > OK, so please explain the big difference between appending to a string > and concatenation :-) > > Most of the time spend in coping strings in memory as result of string > concatenation could be eliminated if you have to think before you do: > > print $string1.$string2; > > or > > print "$string1.$string2"; > > As both of these are inefficient compared to: > > print $string1, $string2; > > or > > printf "%s%s", $string1, $string2; > > unless perl has very clever optimizations. Thus I think that you does > not need string interpolation in BETA, as this tends to make programs > inefficient. Think of strings as immutable objects, and you'll write > more efficient program. Again: you very very often EMBED HTML code in your Perl scripts, so splitting it up again and again does NOT make understanding or modification very easy. It the question: theroretical or preactical? Regards, Sascha Kimmel