1. If either is of type double, the other is converted to double.
2. Otherwise, if either is a float, the other is converted to float.
3. Otherwise, if either is of type long, the other is converted to long.
4. Otherwise, both operands are converted to int.
public class MainClass{
public static void main(String[] argv){
int i=0;
double d = 0D;
int j = i+d;
System.out.println();
}
}
|