Creating a simple Input Output Calculator script that uses Python’s Tkinter GUI!
Used Google Gemini to create the demo link on Github Pages.
Creating a simple Input Output Calculator script that uses Python’s Tkinter GUI!
Used Google Gemini to create the demo link on Github Pages.
The calc is done! Since last time, all the number buttons have been added, and they’ve been lined in up a grid pattern. I kept the 4 basic operators, and to keep the grid aligned/balanced, I added 2 extra buttons: Square root and a decimal button! I also made sure that any invalid operations with the square root would result in an error!
Log in to leave a comment
Learned about spacing using .pack(pady = 5) and figured out how to take a user input that works for all operators! Used Try and Except blocks in all of the operator code as well to exclude value error and divide by 0! Next, I want to make the UI look more like the windows calculator, so that includes: having buttons for numbers 0-9, buttons for clearing, and also having a button for “=”.
Log in to leave a comment
Learned how to import and use a few functions of the Tkinter module! So far, the buttons for the operands ‘+’, ‘-’, ‘x’, and ‘/’ will show up, but not function as intended.
Log in to leave a comment