For those language for which it was easy to make use of an associative
array/hash/mapping: AWK, Bash, Go, Java, Lua, Node.js, Perl, Python,
Ruby and Tcl.
Implementations left without caching: bc, C, Pascal, R, and Scheme.
We now use the same algorithm (but implemented in different languages)
to determine whether a number is a power of 2. This replaces the
preprocessed powers of 2, and lookup tables.