The gist: build a calculator.

Ah, yes, the old calculator. The TI-98. Well, that's pretty advanced. But here the goal is to build a simple calculator that can do the basic mathematical functions. Ideally it'd be able to add, subtract, multiple, divide.

In a very simplistic way, what this project is doing is:

  • Taking user input and sanitizing it
  • Passing it along to the math library in the language you're using
  • Displaying the result

The platform for this could be really just about anything!

  • Command line math tool that parses a string with an equation and prints the results
  • Desktop or mobile app GUI
  • Little web app or component using TypeScript or JavaScript

This is a good project for trying out all sorts of languages and libraries. It doesn't require a data store or networking. It doesn't require an overly complex UI. But it's also not extremely trivial. There's some state to manage and data to sanitize.

I've never made a calculator before, and I think it seems pretty fun to do.


Screenshot of the MacOS calculator:

MacOS calculator

Extra Credit

  • Add more advanced mathematical computations like sine, log, square roots, etc.