• Earn real money by being active: Hello Guest, earn real money by simply being active on the forum — post quality content, get reactions, and help the community. Once you reach the minimum credit amount, you’ll be able to withdraw your balance directly. Learn how it works.

Delphi mReverse [x3] [By Metal]

Status
Not open for further replies.

Expermicid

Leech
User
Joined
Oct 23, 2011
Messages
285
Reputation
0
Reaction score
255
Points
63
Credits
0
‎13 Years of Service‎
95%
mReverse1:

[lenguaje=delphi]Function mReverse1 (Texto: string): string;

var i: integer;

begin

for i:= 1 to length(Texto) do

Result:= Result + Texto[Length(Texto) - (i-1)];

end;[/lenguaje]

mReverse2:

[lenguaje=delphi]Function mReverse2 (Texto: string): string;

var L: integer;

begin

L:= Length(Texto);

while L >= 1 do

begin

Result:= Result + Texto[L];

Dec(L);

end;

end;[/lenguaje]

mReverse3:

[lenguaje=delphi]Function mReverse3 (Texto: string): string;

var L: integer;

begin

L:= length(texto);

if L = 0 then exit;

repeat

Result:= Result + Texto[L];

dec(L);

until L = 0;

end;[/lenguaje]

Autor: Metal_Kingdom

 
Last edited by a moderator:
Status
Not open for further replies.
Back
Top