After a while trying to understand if either ksh or zsh provided a way to prevent taking strings and undefined variables as 0 when doing arithmetic evaluation, there seems to be no feature specifically for it, sadly.
Closest is using set -o nounset (ksh) and setopt no_unset (zsh) to prevent undefined variables from evaluating to zero. If a "string" contains only numbers, a dot and whitespace, it will be treated as a number. Also, if it only contains the name of any other variable and whitespace, it evaluates to that.
Not that I expected shell languages to provide accurate arithmetic.
As a bonus though, it was cool learning about ksh's compound variables, force_float option and especially discipline functions.
There is a new bug fix release of the Korn Shell[1]. Ksh originated as an internal Bell Labs Shell, then as a tool AT&T sold for Unix, and finally the ksh88 version in SVR4 with which AT&T and Sun attempted to merge System V, Xenix, and BSD.
Commercial Unix vendors upgraded to ksh93 and updates ended with ksh93u+ in 2012. Efforts were made to incorporate bug fixes and 93u+m is the most actively maintained continuation.
@hramrach@bagder if you think #bash is horrible (I assume you use #zsh and/or #fish - which then yes that is a valid argument) then please take a look at #ksh, #tcsh or the original #UNIX#sh and tell me that's readable.
Tangents aside: Bash, for better or worse, is the #standard for #Linux and since I want OS/1337 to be "self-reproducing" / "self-hosting" with as little dependencies as possible, I'm stuck with it.
I’m wondering how many people writing programs on #zos under #uss (Unix System Services) using C and #curses library? If you are looking for smell of real Unix development, try to compile here using make (not GNU) pure #vi and sh near to true Born shell (no, it is not #ksh). Anyway curses based menu to present selection list feeding data from stdin is usable from now.
@b0rk I still learn things after 20+ years and I always pick up new things when I am reading something (man pages, articles) idly rather than looking for a solution to a specific problem.
So well-written/fun documentation I would say?
I only started using CDPATH in #ksh this week. By accident.