In my netbeans I had written the following code :
package practicejava;
public class Query {
public static void main(String[] args) {
double d = 4 / 5 / 6;
System.out.println(d);
}
}
Here I was expecting the output to be 0.13333333, but when I run the program it prints 0.
What is the reason of printing 0?