how can i take 1's complement in making a java program?
> You can use Bitwise unary NOT operator Check the Java Language Spec... there no such thing as a "Bitwise unary NOT operator". There is bitwise complement operator, just like the previous poster already said. ps You can also exclusive OR with a value of all 1 bits. Read More
Edited by JamesCherrill: Fixed UK spelling for bitwize (Thanks Tux) ;)