Q. What will be the output of the following Java code?
Code:
class conversion
{
public static void main(String args[])
{
double a = 295.04;
int b = 300;
byte c = (byte) a;
byte d = (byte) b;
System.out.println(c + " " + d);
}
}
β
Correct Answer: (B)
39 44