The use of :

Chang LI changli_to at hotmail.com
Fri Nov 26 12:53:16 EST 2004


Paul Robson <autismuk at autismuk.muralichucks.freeserve.co.uk> wrote in message news:<pan.2004.11.26.08.33.40.219098 at autismuk.muralichucks.freeserve.co.uk>...

> while i > 0 do
>   begin
> 	writeln i;
> 	i := i - 1;
>   end;
> 
> while i > 0:
> 	print i
> 	i = i - 1
> 

So the : is similar to "begin" and the last space line is similar to
"end", right? How about

while i > 0  :
      print i
      i = i-1



More information about the Python-list mailing list