Java Type System: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
No edit summary
 
Line 10: Line 10:


A <tt>char</tt> is stored internally on two [[#byte|bytes]].
A <tt>char</tt> is stored internally on two [[#byte|bytes]].
==short==
A <tt>short</tt> is stored internally on two [[#byte|bytes]].
==int==
A <tt>int</tt> is stored internally on 4 [[#byte|bytes]].
==long==
A <tt>long</tt> is stored internally on 8 [[#byte|bytes]].

Latest revision as of 06:26, 12 November 2016

Internal

Native Types

byte

char

A char is stored internally on two bytes.

short

A short is stored internally on two bytes.

int

A int is stored internally on 4 bytes.

long

A long is stored internally on 8 bytes.