Hello,
I am not able to understand the following code :-
class Demo {
public static void main(String[] args){
long m =20l;
float n =30f;
n=m;
System.out.println("The value of n is "+n);
}
}
Problem is : long is 64 bits and float is 32 bits, but when we assign a long to float it doesn't give a error, while when we want to do a narrowing casting we should have to do explicit cast.
Vaibhav