Re: "For" keyword not necessary, plus variable types maybe not necessary.
- From: Keith Latham <newsletters@xxxxxxxxxxx>
- Date: Fri, 01 Feb 2008 02:17:11 +1100
Skybuck Flying wrote:
Hello,
Following code could work:
procedure Main;
var
vIndex;
begin
vIndex := 1 to 100 do
begin
end;
end;
The to and do keywords should be enough for the compilers to figure out it's a for loop
The numbers indicate it should be some kind of integer so take the integer that will fit.
No need to write lengthy code like:
procedure Main;
var
vIndex : integer;
begin
for vIndex := 1 to 100 do
begin
end;
end;
Bye,
Skybuck.
you don't need to write lengthy code like 'begin' or 'end' either. why not '{' and '}'?
.
- References:
- "For" keyword not necessary, plus variable types maybe not necessary.
- From: Skybuck Flying
- "For" keyword not necessary, plus variable types maybe not necessary.
- Prev by Date: Re: Some like it horizontal, some like it vertical :)
- Next by Date: Re: TChart: sliding window??
- Previous by thread: Re: "For" keyword not necessary, plus variable types maybe not necessary.
- Next by thread: procedure ( a : integer; b : integer; ); would be nice.
- Index(es):
Relevant Pages
|