[erlang-questions] Equal binaries with different integers
Bob Ippolito
bob@REDACTED
Mon Apr 29 10:31:38 CEST 2019
It's possible because the default size for an integer in bit syntax is 8.
1> 24930 rem 256 =:= 98.
true
For further explanation of this behavior you can take a look at this
section of the documentation:
http://erlang.org/doc/programming_examples/bit_syntax.html#Defaults
-bob
On Mon, Apr 29, 2019 at 1:27 AM DOBRO <chessvegas@REDACTED> wrote:
> Hi,
> could anyone explain me how is it possible?
>
> In shell:
>
> 1> <<24930>> =:= <<98>>.
> true
>
>
> I'm using OTP-21.3.7.
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20190429/efca8955/attachment.htm>
More information about the erlang-questions
mailing list