double result1 = Math.Ceiling(0.3); Console.WriteLine(result1);//result1显示1 double result2 = Math.Ceiling(0.5); Console.WriteLine(result2);//result2显示1 double result3 = Math.Ceiling(0.6); Console.WriteLine(result3);//result3显示1 Console.Read();
Math.Ceiling 只要有小数都加1
猜你喜欢
转载自www.cnblogs.com/158-186/p/10894743.html
今日推荐
周排行