int a=1;
float b=1.0;
System.out.println(a==b);
Answer Posted / anil kumar rai
error found when compile this code;
if u write 1 in place of 1.0 then output would be "true" or
if u write double in place of float then output would be
same :"true"
thank you
| Is This Answer Correct ? | 13 Yes | 1 No |
Post New Answer View All Answers
What is exception in java?
What does compareto () do in java?
Difference between object instantiation and construction ?
Explain importance of finally block in java?
Can java object be locked down for exclusive use by a given thread?
What is thread life cycle in java?
Why Do I Get A "permission Denied" Error After Downloading The .jnlp Java Launcher For The Vkvm?
What is an example of character?
What are default methods ?
Why do we need singleton class?
What is 16 bits called?
Can we clone singleton object?
What is prefix of a string?
Difference between vector and arraylist.
Is java a pure object oriented language?