HELP ME
while coinIndex < len(coins):
# Get a coin from the coins array using coinIndex
coinIndex
# Collect that coin.
hero.moveXY(coin pos.x, coin.pos.y)
# Increase coinIndex by one.
coinIndex += 1
HELP ME
while coinIndex < len(coins):
# Get a coin from the coins array using coinIndex
coinIndex
# Collect that coin.
hero.moveXY(coin pos.x, coin.pos.y)
# Increase coinIndex by one.
coinIndex += 1
Fixed your overuse of characters.
Here, you never defined coin. Do coin=coin[coinIndex] which gets a coin for us.
You forgot the the period between coin and pos.
okay thanks you helped me a bit but now it says line 16 ReferenceError: coinIndex is not defined
You forgot to define coin index before the loop
how do i do that???

I told you, you define coinIndex=0 before the loop.
okay thanks 



This topic was automatically closed after 33 hours. New replies are no longer allowed.