Online Java Compiler By
JavaTpoint.com
public class NextUpExample1 { public static void main(String[] args) { float x = 0.0f / 0; // Input NaN, Output NaN System.out.println(Math.nextUp(x)); } }
Output