Re: length() and looping

new topic     » goto parent     » topic index » view thread      » older message » newer message
integer len = 5 
 
for i = len/2 + 1 to len do 
   ? i 
end for 
 
-->> 3.5 
-->> 4.5 
 
-- never gets to 5.5 since it is larger that "5" 

but, when outputing your data, you are using the implicit truncation of index values so, you "loose" that index value that should have been 5.5 truncated

_tom

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu