Article View: pl.comp.lang.delphi
Article #334852Re: [outro] ]Re: Delphi do zastosowan domowych
From: R.e.m.e.K
Date: Thu, 19 Jan 2012 17:56
Date: Thu, 19 Jan 2012 17:56
43 lines
1838 bytes
1838 bytes
Dnia Thu, 19 Jan 2012 18:48:29 +0100, Wojciech "Spook" Sura napisaล(a):
>> var
>> SL : TStringList;
>> begin
>> SL := GetStringListWithContent;
>> result := 'Zawartosc listy: [' +
>> (function (Str : TStrings) : string
>> var
>> s : string;
>> begin
>> for s in Str do s := s + CRLF;
>> result := s;
>> end;
>> )(SL) + ']';
>> SL.Free;
>> end;
>
> {
> std::vector<std::string > & SL = GetStringListWithContent();
>
> auto result = [&SL]() -> std::string
> {
> std::string tmp;
> for (int i = 0; i < SL.size(); i++)
> tmp += (SL[i] + "\n");
> return tmp;
> }();
> }
Ale jaka brzydka petla for :-P :-P
No dobra, ruki wierch, poddaje sie, nie znam C++ i troche pojechalem po
bandzie, ale chcialem pokazac co mozna zrobic w Delphi i to mnie czesciowo
tlumaczy :-)
ps. to jest tez funkcja anonimowa?
--
pozdro
R.e.m.e.K
Technical Details
Message-ID:
<1i4rse32tw0m7.dlg@hell.heaven>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!.POSTED!not-for-mailReferences:
<1nva6kty8t73b$.dlg@hell.heaven> <jf99kg$t6e$1@news.dialog.net.pl> <162t4ulo0stz4.dlg@hell.heaven> <op.v8cee3coyumhbd@notebook.asus>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!.POSTED!not-for-mail From: "R.e.m.e.K" <go@dev.null> Newsgroups: pl.comp.lang.delphi Subject: Re: [outro] ]Re: Delphi do zastosowan domowych Date: Thu, 19 Jan 2012 18:56:24 +0100 Organization: ICM, Uniwersytet Warszawski Lines: 43 Sender: hell@heaven Message-ID: <1i4rse32tw0m7.dlg@hell.heaven> References: <1nva6kty8t73b$.dlg@hell.heaven> <jf99kg$t6e$1@news.dialog.net.pl> <162t4ulo0stz4.dlg@hell.heaven> <op.v8cee3coyumhbd@notebook.asus> NNTP-Posting-Host: 89-75-115-216.dynamic.chello.pl Mime-Version: 1.0 X-Trace: news.icm.edu.pl 1326995781 31115 89.75.115.216 (19 Jan 2012 17:56:21 GMT) X-Complaints-To: usenet@news.icm.edu.pl NNTP-Posting-Date: Thu, 19 Jan 2012 17:56:21 +0000 (UTC) User-Agent: 40tude_Dialog/2.0.15.1pl Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit