Hej there,
I stumbled upon the continue statement and to me it looks like it
does exactly the same as else. I tested both else and continue in a
little program and I don't see any differences between both. Is my
assumption correct or wrong? If the latter is the case: Can you give
me examples of
Hi,
I stumbled upon the continue statement and to me it looks like it
does exactly the same as else. I tested both else and continue in a
little program and I don't see any differences between both. Is my
assumption correct or wrong? If the latter is the case: Can you give
me examples of
On Sun, Nov 24, 2013 at 4:41 PM, Dominik George n...@naturalnet.de wrote:
Hi,
I stumbled upon the continue statement and to me it looks like it
does exactly the same as else. I tested both else and continue in a
little program and I don't see any differences between both. Is my
assumption
On 24/11/13 21:32, Rafael Knuth wrote:
I stumbled upon the continue statement and to me it looks like it
does exactly the same as else. I tested both else and continue in a
little program and I don't see any differences between both.
for num in range(2,10):
if num % 2 == 0:
On 24/11/13 22:38, Alan Gauld wrote:
Responding to my own post, never a good sign :-(
primes = []
for n in range(1000)
if n%2 == 0: even numbers aren't prime
continue
else:
if isPrime(n):
primes.append(n)
Now the continue means the isPrime test never gets
On 24/11/2013 21:41, Dominik George wrote:
Hi,
I stumbled upon the continue statement and to me it looks like it
does exactly the same as else. I tested both else and continue in a
little program and I don't see any differences between both. Is my
assumption correct or wrong? If the latter is
On Sun, Nov 24, 2013 at 10:32:20PM +0100, Rafael Knuth wrote:
Hej there,
I stumbled upon the continue statement and to me it looks like it
does exactly the same as else. I tested both else and continue in a
little program and I don't see any differences between both.
continue and else are