File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes range of primitives Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Professional Certification » Programmer Certification (SCJP/OCPJP)
Reply Bookmark "range of primitives" Watch "range of primitives" New topic
Author

range of primitives

devi nachimuthu
Greenhorn

Joined: Jan 07, 2003
Posts: 10
What is the legal range of byte integral type...?
a) 0 - 65,535
b) (-128) - 127
c) (-32,768) - 32,767
d) (-256) - 255
I think the answer is b.
I saw this question in two different papers... They have two different answers which are b and c. Whcih one is correct...?
Vasanth Appaji
Greenhorn

Joined: Aug 22, 2000
Posts: 13
b is the right one. -32768 to 32767 is for short.
 
 
subject: range of primitives
 
Threads others viewed
equals() question required
Object comparasion question
Jakob Nielsen Declares the Letter "C" Unusable
Public Variables
Equals doubt
MyEclipse, The Clear Choice