Reverse Pascal loop like in VB
I have a 'For' loop that displays pages in a Wizard.
The loop looks like this:
for i := 0 to nodes.开发者_如何转开发Length - 1 do
begin
end;
How to reverse it to display last items first? In VB, I would add a Step -1
to the loop to start with the last item. How to accomplish the same behavior in Pascal?
for i := nodes.Length - 1 downto 0 do
begin
end;
精彩评论