Run ❯
Get your
own Java
server
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
public class Main { public static void main(String[] args) { System.out.println(Math.nextDown(1.0f)); System.out.println(Math.nextDown(1.0)); System.out.println(Math.nextDown(0.5f)); System.out.println(Math.nextDown(0.5)); System.out.println(Math.nextDown(Math.PI)); System.out.println(Math.nextDown(3.1415927f)); } }
0.99999994
0.9999999999999999
0.49999997
0.49999999999999994
3.1415926535897927
3.1415925