Or you can just keep a terminal window open with python running (doesn’t matter much that Macs have 2.7 by default)
- (45. / 7.)**(1./2.)
10.1418510567422import math
math.hypot(3,4)
5.0
math.factorial(12)
479001600
Unfortunately you do need to put in the decimal points throughout for things like the first example, but that’s an easy habit to form if you do it enough. There are also scads of calculator programs written in python for the command line. Test them first, many are student projects…
You can install SciPy and get not only get better calculating, but symbolic math, graphing and much more:
You can install Sage, which is even more comprehensive than SciPy, or use the free cell server (no account needed, but it’s heavily used and slow). IIRC there’s also a Sage iOS app that connects to the server.
https://www.sagemath.org/
A Tour of Sage
https://sagecell.sagemath.org/
Or, you could do something completely different, and use the APL tutorial website. It’s a bit like TECO, for those old enough to remember that: cryptic and powerful. (But it leaves out the “dangerous”.) For anyone who gets hooked, Dyalog APL is free for non-profit individual use. (Commercial APL interpreters are stupidly expensive, because the primary user is the insurance industry.)
Game of Life in APL (about 7 minutes):