private static object Odd(List <Expression> p) { var num = (int)Math.Ceiling(p[0]); var addValue = num >= 0 ? 1 : -1; return(XLMath.IsOdd(num) ? num : num + addValue); }
public void IsOdd() { Assert.IsTrue(XLMath.IsOdd(3)); Assert.IsFalse(XLMath.IsOdd(2)); }