>>34
Wow you're stupid. You just don't get it. There's more to unsigned integers than just "reading" them as you put it. Just because they're two's complement notation doesn't mean that you can use signed comparisons on numbers where you expect unsigned semantics.
// C version, assuming int is a 32-bit integer on target platform
unsigned int a = 0xFFFFFFFF;
unsigned int b = 0x00000005;
if (b < a) {
printf("fuck you >>34\n");
}
// Java version
int a = 0xFFFFFFFF;
int b = 5;
if (b < a) {
System.out.println("fuck you >>34\n");
}
The C version will print the message, whereas the Java version will not. There are different semantics involved. In C compilers and the JVM, with signed integers, signed comparison machine instructions are emitted. For unsigned types in C, unsigned comparison instructions are used. There is a difference which affects order. In Java, the only way to get the same semantics is to use a larger signed integer type which can represent all of the unsigned values possible with the smaller unsigned type.
You're also stuck in OO-thought processes focused on tiny toy one-man projects. In large scale projects, if you have to support lots of unsigned integers has a big impact.