unsigned int a =0xffff;
gives output ffff
Complementing function works here.
What's use of 0x in 0xffff as unsigned int is of 2 bytes only???
Can anybody suggest???
[inlinecode]~a[/inlinecode] flips the bits in a, but doesn't save the result anywhere. On the next line, a is still equal to 0xffff. 0x marks that the value is written in hexadecimal (simlarly, a number preceded by a 0, such as 024, is written in octal). Lastly, and unsigned int is … Read More
[QUOTE=Infarction;251961]Lastly, and unsigned int is the same size as an int, which is 4 bytes on a 32-bit CPU and 8-bytes on a 64-bit CPU[/QUOTE]Maybe true, maybe not. Making size assumptions is not really helpful. Read More