1、CEIL() 向上取整 SELECT CEIL(1/2); 12、FLOOR() 向下取整 
SELECT FLOOR(0.6); 03、ROUND() 四舍五入 SELECT ROUND(1.5); 2
                            
                            
                                分类:
数据库   时间:
2014-06-06 18:12:29   
                                阅读次数:
435
                             
                         
                    
                        
                            
                            
                                Document
	
		function figure1(){
			var figure = money.value;
			var wushi = Math.floor(figure/50);
			var ershi = Math.floor(figure%50/20);
			var shiyuan = Math.floor(figure%50%20/10);
			var wuyuan...
                            
                            
                                分类:
编程语言   时间:
2014-06-03 03:13:19   
                                阅读次数:
284
                             
                         
                    
                        
                            
                            
                                freemarker中的round、floor和ceiling数字的舍入处理
1、简易说明
(1)round:四舍五入
(2)floor:向下取整
(3)ceiling:向上取整
2、举例说明
     
     
     
     
     
     
     
         ${num} ?round=${num?round} ?floor=...
                            
                            
                                分类:
其他好文   时间:
2014-06-01 15:29:34   
                                阅读次数:
218
                             
                         
                    
                        
                            
                            
                                摩擦运动:逐渐变慢,最后停止缓冲运动:与摩擦力的区别:可以精确的停到指定目标点距离越远速度越大速度由距离决定速度=(目标值-当前值)/缩放系数Bug:速度取整值取整:iSpeed 
= iSpeed > 0 ? Math.ceil(iSpeed) : Math.floor(iSpeed); 1 2.....
                            
                            
                                分类:
Web程序   时间:
2014-05-29 23:36:27   
                                阅读次数:
414
                             
                         
                    
                        
                            
                            
                                题目:The famous ACM (Advanced Computer Maker) 
Company has rented a floor of a building whose shape is in the following figure. 
The floor has 200 rooms e...
                            
                            
                                分类:
其他好文   时间:
2014-05-28 18:57:31   
                                阅读次数:
311
                             
                         
                    
                        
                            
                            
                                Problem APlay with Floor and CeilInput:standard 
inputOutput:standard outputTime Limit:1 secondTheoremFor any two 
integersxandkthere exists two more in...
                            
                            
                                分类:
其他好文   时间:
2014-05-26 14:21:44   
                                阅读次数:
270
                             
                         
                    
                        
                            
                            
                                最近在网上找了下mysql查询随机的几个sql,我把最终的记录下来。 SELECT * 
FROM uchome_mtag AS a JOIN (SELECT MAX(tagid) AS id FROM uchome_mtag) AS b ON 
(a.tagid>=FLOOR(b.id*RAND())...
                            
                            
                                分类:
数据库   时间:
2014-05-26 08:51:19   
                                阅读次数:
317
                             
                         
                    
                        
                            
                            
                                0, "days" => 0, "hours" => 0, "minutes" => 
0, "seconds" => 0, ); if($time >= 31556926){ $value["years"] = 
floor($time/31556926); $time = ($t...
                            
                            
                                分类:
Web程序   时间:
2014-05-20 12:07:09   
                                阅读次数:
252
                             
                         
                    
                        
                            
                            
                                整理使用Javascript函数将数值保留两位小数: 1.num.toFixed(2) 
//进位 2.(Math.round(num * 100) / 100).toFixed(2) //进位 3.(Math.floor(num * 100) / 
100).toFixed(2) //不进...
                            
                            
                                分类:
编程语言   时间:
2014-05-20 08:05:53   
                                阅读次数:
456