AT&T Archives: The UNIX operating system

$ dc | number | speak :D
Playing around with dc(1), that I always found hard to understand, I noticed 'p' was obviously very common to print something on the screen at that time.
Got a new boost of motivation and studied its cryptic manpage once again.
Made some useful progress and can finally drop my pocket calculator.

In the future I will only be doing like: "Hey computer, how many bytes are there in 24GiB of RAM?"
...and the answer will be dc -e '2 30 ^ 24 * p' | number | espeak

It feels good to get my head around tools that used to be like Chinese to me :)
 
I like dc(1) but mainly because I'm used to using RPN. I had (and still have) a HP-48 calculator when I was in school. If you're not used to RPN you could use bc(1) instead. Same kind of calculator as dc(1) but using the "normal" way.
 
I should have looked RPN up myself. Guess I had understood that pushing on/off the stack stuff much earlier.
Anyway, even if I'm new to RPN, I think it definitely adds to readability compared to the same calculation in bc and I like it.
 
$ dc | number | speak :D
Playing around with dc(1), that I always found hard to understand, I noticed 'p' was obviously very common to print something on the screen at that time.
Got a new boost of motivation and studied its cryptic manpage once again.
Made some useful progress and can finally drop my pocket calculator.

In the future I will only be doing like: "Hey computer, how many bytes are there in 24GiB of RAM?"
...and the answer will be dc -e '2 30 ^ 24 * p' | number | espeak

It feels good to get my head around tools that used to be like Chinese to me :)
"Hey computer, what's the weather like in vladivostok?"
finger o:vladivostok@graph.no | tail -n 1 | espeak
 
Back
Top