Java tutorial
//package com.java2s; public class Main { static double roundOne(double f) { long templ = Math.round(f * 10); double retd = templ / 10.0; return retd; } }