class Round2Scales
{
  public static double roundScale2( double d )
  {
    return Math.rint( d * 100.0 ) / 100.0;
  }
  
  public static double roundScale22( double d )
  {
    return Math.round( d * 100.0 ) / 100.0;
  }
  
  public static void main( String[] args )
  {
    System.out.println( roundScale2(+1.341 ) );  //  1.34
    System.out.println( roundScale2(-1.341 ) );  // -1.34
    System.out.println( roundScale2(+1.345 ) );  //  1.34 !!
    System.out.println( roundScale2(-1.345 ) );  // -1.34
    System.out.println( roundScale2(+1.347 ) );  //  1.35
    System.out.println( roundScale2(-1.347 ) );  // -1.35
    
    System.out.println( roundScale22(+1.345 ) ); //  1.35 !!
    System.out.println( roundScale22(-1.345 ) ); //  1.34
  }
}
