Subleq: Difference between revisions
→bash: lowercase non-env vars; take advantage of arithmetic contexts; use printf instead of echo
m (→{{header|Ruby}}: mild idiomaticity adjustment) |
(→bash: lowercase non-env vars; take advantage of arithmetic contexts; use printf instead of echo) |
||
Line 3,086:
</lang>
===bash===
<lang bash>#!/usr/bin/
mem=(15 17 -1 17 -1 -1 16 1 -1 16 3 -1 15 15 0 0 -1
72 101 108 108 111 44 32 119 111 114 108 100 33 10 0)
while
(( step++ ))
if
printf '%b' '\x'$(printf '%x' ${mem[
else
▲ ADDR=$C
fi
fi
done
</lang>
|