def round_float(float, places)
      factor = Float(10 * places)
      Float((float * factor).round / factor)
    end
def round_float(float, places)
      factor = Float(10 * places)
      Float((float * factor).round / factor)
    end
ruby 1.9 could use Float#round(places) instead
 @return [Float]