Scalar. Returns the value of an expression after setting a specific bit to 1.
bitset ( expression, bit )
expression | The initial value as an integer or a long. |
bit | Which bit to set, starting from 0 as the least-significant bit. |
A bit argument must be an integer. The function returns the same datatype as the initial expression argument.
bitset (2, 3) returns 10, or in binary, bitset (0010, 3) returns 1010. The user cannot specify binary directly.