Browse Source

fix issue #983 INT(1.99) doesn't return correct rounded value

pull/1109/head
JY Yu 2 years ago
parent
commit
81d6a55ab9
  1. 5
      main/SS/Formula/Functions/Int.cs

5
main/SS/Formula/Functions/Int.cs

@ -31,10 +31,7 @@ namespace NPOI.SS.Formula.Functions
public override double Evaluate(double d)
{
if (d > 0)
return Math.Round(d - 0.49);
else
return Math.Round(d - 0.5);
return Math.Floor(d);
}
}
Loading…
Cancel
Save