An integer is a basic type having a number of binary bits.
Depending on your processer architecture this might be 32 or 64 bits.
The binary and (&) operator performs a bitwise "AND" operation on the
integer which effectively removes all but the least significant bit of the
integer. This may be 1 or 0 depending on the value.
In the case that it is indeed 1, the number is odd.
He didn't write 'int' but 'integer'. An integer is a mathematical concept,
an int in C# is an alias for a System.Int32 which is an integer represented
in the architecture as 32 bits as opposed to an Int64.
He didn't write 'int' but 'integer'. An integer is a mathematical
concept, an int in C# is an alias for a System.Int32 which is an integer
represented in the architecture as 32 bits as opposed to an Int64.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.