Online Java Compiler By
JavaTpoint.com
public class FloorDivExample2 { public static void main(String[] args) { int x = -25; int y= 3; // -25/3 value is -8.333 so floor(-8.333) = -9 System.out.println(Math.floorDiv(x, y)); } }
Output