Quick math on the terminal
Hey there!
Just this past week I stumbled on a HN comment from 2019. The commenter was fiddling with some scripts to perform some simple math directly on the (bash) terminal.
TLDR: Click here to go to the code and skip the backstory.
What the commenter proposed was something like this, based on the dc command (comments are mine).
$ . calc.sh # Load functionality $ * 4 5 # Multiply 4 and 5 20 $ / 21 3 # Divide 21 by 3 7 This sounded interesting.
[Read More]