Which of the following is not considered as data type in Java?
String
int
boolean
double
Answer and explanation
No explanation is available for this question yet.
ObjectiveMcq
Print Protected
This page is protected for print. Use the website to view the content.
9 practice sets · Page 1 of 1
Which of the following is not considered as data type in Java?
String
int
boolean
double
No explanation is available for this question yet.
What is the range of 'byte' data type?
-127 to 127
-128 to 128
-127 to 128
-128 to 127
No explanation is available for this question yet.
Which of the following is default value of 'double' data type?
0
0.0d
null
False
Default value is assigned to a variable by memory when it is declared but not initialized.
Which of the following is default value of 'int' data type?
0
null
True
False
Default value is assigned to a variable by memory when it is declared but not initialized.
What is the range of 'short' data type?
-(2^15+1) to (2^15-1)
-2^15 to 2^15
-(2^15-1) to (2^15+1)
-(2^15-1) to 2^15
No explanation is available for this question yet.
What is the maximum value of 'byte' data type?
2^7
2^7+1
2^7-1
None of the mentioned
No explanation is available for this question yet.
What is the minimum value of 'short' data type?
-32,768
-127
-2,147,483,648
-32,767
No explanation is available for this question yet.
What is the size(in bytes) of 'byte' primitive data type?
4
1
2
8
'byte' is a signed 8-bit(1byte) data type defined by Java.
Which of the following data type is used to fetch stream of data from network or file?
char
int
byte
double
When input is taken from keyboard or file it is taken in the form of bits by the machine. Byte is a collection of bits that makes user read a character at the output at a time. Usage of byte also saves memory.