I am using nodejs 16 and I have below code:
> a=Math.pow(2, 31)
2147483648
> a|a
-2147483648
As you can see the result of a|a is negative value. I expect to be the same value as a. But why it gives me negative value? What can I do to get the original value?