[erlang-questions] Literal support for unary (1#XXXXXX...)

Andrew Pennebaker <>
Sun Jun 2 21:40:08 CEST 2013

> How base 1 works? Could you explain to me please? Is it number or digits
> after dash?

Typically, the value of a base 1 is the number of 1's. So three in base ten
would be 1#111.


As Masklinn points out, the digits used don't really matter because we're
just evaluating the length. It could be X's, 3's, or chicken scratches,
zeroes, capital I's, or a mix of 1#AlPhAbEt SoUP. Though I think for
clarity, we should select a single permissible character and stick to it.
Something like tally marks.


Andrew Pennebaker
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20130602/1e719571/attachment.html>

More information about the erlang-questions mailing list