Java tutorial
public class Main { public static void main(String[] args) { double d1 = 12.34, d2 = 56.78; System.out.println("closest long value to " + d1 + " = " + StrictMath.round(d1)); System.out.println("closest long value to " + d2 + " = " + StrictMath.round(d2)); } }