Home / Questions / State the number of bytes occupied by char and int data types.
Explanatory Question

State the number of bytes occupied by char and int data types.

👁 72 Views
📘 Detailed Answer
🕒 Easy to Read
Read the answer carefully and go through the related questions on the right side to improve your understanding of this topic.

Answer with Explanation

char occupies 2 bytes and int occupies 4 bytes.

Java Primitive Data Types
Figure: Java Primitive Data Types