For curious readers who want to try Bad Banana, but who, understandably, would prefer not to have to download the code and run it on their systems, the game can now be safely played online at https://trinket.io/python/6a564db039?toggleCode=true&runOption=run. Toggle to Code View to see how the game works!
Many thanks to the people behind trinket.io, a great tool for beginners to learn about coding and to share simple programs like Bad Banana.
It’s been awhile since my last entry, but here is my latest creation, so to speak.
Bad Banana is a text-based math game written in Python 3. My original intention was to use the game as a way to teach basic programming concepts, but I’ve put that idea on hold–I feel it right that I get better at coding first before I attempt to instruct others. The challenge of the game is to mentally multiply two whole numbers as many times as you can before getting three wrong answers. Once that happens, it’s game over and you’re a BAD BANANA🍌 💩 !
Obviously that was funnier in my head :-p.
Watch the video above to see the game run in IDLE. Alternatively, you can view and download the code from my github repository, and run it however you like on your system. I’m going to try to see if I can actually embed the game on WordPress so readers can play it live on this blog.
Enjoy (I hope)!
P.S. I did not display the code here because WordPress made some unasked changes to it when I used the “code” tags. Very bizarre, but it’s available at github, as mentioned above.