Re: frustrating failure of 'break' statement ( novice )

2009-06-13 Thread Rhodri James
On Sat, 13 Jun 2009 22:48:43 +0100, wrote: In my programs the 'break' fails to work. I've studied the docs for 3.0 and Programming in Python, neither of which are illuminating. Simplest example : while True : num = int(input()) print(num) if num == 0 : break print('done')

Re: frustrating failure of 'break' statement ( novice )

2009-06-13 Thread Mark Dickinson
On Jun 13, 10:48 pm, pdlem...@earthlink.net wrote: > In my programs the 'break' fails to work.  I've studied the docs for > 3.0 and Programming in Python, neither of which are illuminating. > Simplest example : > > while True : >     num = int(input()) >     print(num) >     if num == 0 : >        

frustrating failure of 'break' statement ( novice )

2009-06-13 Thread pdlemper
In my programs the 'break' fails to work. I've studied the docs for 3.0 and Programming in Python, neither of which are illuminating. Simplest example : while True : num = int(input()) print(num) if num == 0 : break print('done') SyntaxError : invalid syntax( pointing t