I'm working on a code for a 'casino' in Python (no GUI yet, just trying to get the codes down for now). I want coins to be a system of currency, and I have a perfectly fine Russian Roulette code. If the player survives, I want the code to add onto the player's coins. Said coins are already defined at the top of the code, outside of the function. When I try
return coins += 100
at the elif clause for the player's survival, I immediately get "invalid syntax" in IDLE.
How can I have the function modify 'coins'?