When the Find the inverse of a number
1/x challenge has been posted, the author posted a bounty for the shortest Retina submission. After that, there was a bounty for sed, another text/string-based language. Since the challenge requires I/O with floating-point numbers, this brings forth a question: how will floating-point numbers be represented in unary?
In unary an integer, say
5, would be represented with that many zeroes, in this case,
00000. What about decimal places? One suggestion was to do the same thing for decimal places as well, for example
4.3 would be
0000.000... BUT what about
4.03? It will share its representation with
4.3, so clearly this way of using unary to show decimal numbers (as in decimal places and not base-10 numbers) would not be valid.
How do we represent floating-point numbers in unary?