Check out this Code & Suggest me the Improvement | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
14th Feb 2024, 1:13 PM
Sanjaykrishna Hegade šŸ‡®šŸ‡³
Sanjaykrishna Hegade šŸ‡®šŸ‡³ - avatar
2 Respostas
+ 1
Sanjaykrishna Hegade šŸ‡®šŸ‡³ the bug is in move_player(). When the die roll would result in an invalid move the move_player() function fails to return any value, so the calling procedure gets None and assigns that to its new position. Later, the logic tries to perform addition with None, but Python does not allow it. Insert at line 37: return player
14th Feb 2024, 3:45 PM
Brian
Brian - avatar
0
Use Feed post for suggestions.
14th Feb 2024, 3:05 PM
AĶ¢J
AĶ¢J - avatar