I have been programming in Java since 2004, mostly enterprise and web applications. But I have never used short or byte, other than a toy program just to know
The Java language itself makes it unreasonably difficult to use the byte
or short
types. Whenever you perform any operation on a byte
or short
value, Java promotes it to an int
first, and the result of the operation is returned as an int
. Also, they're signed, and there are no unsigned equivalents, which is another frequent source of frustration.
So you end up using byte
a lot because it's still the basic building block of all things cyber, but the short
type might as well not exist.