Given: What is the result?
A.
c = null b = false f = 0.0F
B.
c = b = false f = 0.0
C.
c = 0 b = false f = 0.0f
D.
c = null b = true f = 0.0
Given: What is the result?
A.
c = null b = false f = 0.0F
B.
c = b = false f = 0.0
C.
c = 0 b = false f = 0.0f
D.
c = null b = true f = 0.0
Answer B
===> if you print an uninitialized char variable , you’ll get nothing.
char c;
boolean b;
float f;
void printAll() {
System.out.println(“c = ” + c);
System.out.println(“c = ” + b);
System.out.println(“c = ” + f);
}
public static void main(String[] args) {DoClass f = new DoClass();
f.printAll();
}
no, you have to try make some math task on this variables
b