why the primitive data type have classes?

Answer Posted / ranganathkini

All of Java's primitive data types have an associated
Wrapper class. These wrapper classes provide useful
functions such as conversion or comparisons most of which
are used by Java implicitly.

Also a wrapper serves as a container for primitive values in
conditions where a reference type is expected.

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is your platform?s default character encoding and how to know this?

2046


Does java support multiple inheritances?

820


What is the numeric promotion?

735


Can we execute a program without main() method?

783


How to use arraylist in java netbeans?

761


What is the final keyword denotes?

897


What is java util collection?

792


What is the new line character?

869


What is backdrop?

831


How many threads can I run java?

824


If we allocate the memory using 'new' & de-allocated using 'free' then what will happen?

827


What is a module function?

828


What is null data type?

742


What is flag in python?

841


How many characters is 2 bytes?

769