Unknown syntax error.
Posted
by matt1024
on Stack Overflow
See other posts from Stack Overflow
or by matt1024
Published on 2010-03-24T21:59:59Z
Indexed on
2010/03/24
22:03 UTC
Read the original article
Hit count: 269
python
Why do I get a syntax error running this code? If I remove the highlighted section (return cards[i]) I get the error highlighting the function call instead.
Please help :)
def dealcards():
for i in range(len(cards)):
cards[i] = ''
for j in range(8):
cards[i] = cards[i].append(random.randint(0,9)
return cards[i]
print (dealcards())
© Stack Overflow or respective owner