Beispiel #1
0
        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);
        }
Beispiel #2
0
 public void IsOdd()
 {
     Assert.IsTrue(XLMath.IsOdd(3));
     Assert.IsFalse(XLMath.IsOdd(2));
 }