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 purpose do the keywords final, finally, and finalize fulfill?

618


What does string intern() method do?

594


Why are the destructors for base class and derived class called in reverse order when the program exits

1712


What are parsers? Dom vs sax parser.

563


Is ruby built on java?

537






What is a line break?

586


Is java 9 released?

528


Explain about fail safe iterators in java?

570


What is unicode with example?

616


Explain what access modifiers can be used for methods?

572


Is string is a data type in java?

595


Why do we use return statement?

547


What is java literals?

586


What does sprintf mean?

540


What is the point of java?

560