On Jun 20, 2008, at 09:34, Max Berger wrote:
The JVM converts all shorts to ints before doing any arithmetic, so
shorts are actually a little bit slower than ints.
As for the size: If you have primitive values, an int takes up 4 byte,
whereas a short takes 2 bytes (+java overhead), meaning
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Andreas,
The JVM converts all shorts to ints before doing any arithmetic, so
shorts are actually a little bit slower than ints.
As for the size: If you have primitive values, an int takes up 4 byte,
whereas a short takes 2 bytes (+java overhead),