Bank Interface (Absolutely not like a pro)

--Originally published at Nihilistic Kirby

So yesterday I started writing a code where I could mix the basic command to display a message “print“, variables, inputs input, the type conversion functions like “str (to convert inputs into strings), int (to convert inputs into integers), and float (to convert inputs into numbers with decimals)”, also a simple loop using while and True (I honestly don’t know exactly how to describe this type of command; however, I got a logical idea, which I can’t explain, that helps me to understand the use of it.)

So before showing and explaining how frustrating for me it was to work out all of this, here’s the interpretation of my code using the terminal for Windows:

banko

You may already have an idea of how this works, however, I’d like to share how most of my code works (using a picture because I still don’t know how to correctly write down the code, lol):

bankvisual

Notice the use of a function in order to call the menu every time after any option (a, b, c, or d) is executed.

The most difficult part of this program was to update the variable ‘balance’ as the other two variables (‘deposit’ and ‘draw’) changed, but at the end it was logic and a little help of Martín (ISC’s director) what made me finish what I was planing to do. I won’t lie, it took me about an hour to finish it, because I haven’t programmed anything in python or another languages ever before, but the satisfaction of getting something  (despite the code is too small) done is what makes me keep trying new projects every single time, even if I’m about to lose my mind.