News for hackers. Stuff that matters.
Re:Unix History and the `DC` Calculator by gavinhoward on Sunday September 01, 2024 @10:09PM (#41422047)
As the author of a `dc` (https://git.gavinhoward.com/gavin/bc), I appreciate this article!

The author is correct on the parsing of "normal" vs. Reverse Polish notation. My `bc`, with normal expressions, needs 1555 LoC for parsing. My `dc` needs just 298.

I have a couple posts ([1], [2]) about `dc` tricks and code on my blog.

And yes, I have an HP 48G [3]. :)

[1]: https://gavinhoward.com/2019/12/bc/dc-tips-and-tricks/

[2]: https://gavinhoward.com/2021/04/a-dc-script-for-easter/

[3]: https://gavinhoward.com/uploads/easter-dc-script/hp-48g.jpg

Re:Unix History and the `DC` Calculator by fsckboy on Monday September 02, 2024 @12:02AM (#41422467)
is your bc the bc or is it a bc? bc is a POSIX standard so "a" bc would be as good as "the" bc, i'm just curious. "man bc" on Fedora linux says the author is Phil Nelson
Re:Unix History and the `DC` Calculator by gavinhoward on Monday September 02, 2024 @12:22AM (#41422552)
Depends on what platform you are using. Most Linux distros? Only a bc. FreeBSD and macOS? The bc. [1]

[1]: https://gavinhoward.com/2023/02/my-code-conquered-another-os...

Re:Unix History and the `DC` Calculator by whartung on Sunday September 01, 2024 @10:52PM (#41422241)
iHP48 on iOS is excellent. It’s my mostly go to calculator on the go. I find the lack of a backlight on the legacy HPs to make usage difficult (plus I always have my phone).