a = 1234.5678;
Math.floor(a); //123 (버림)
Math.round(a); // 1235 (반올림)
Math.ceil(a); // 1235 (무조건 올림)
'자바스크립트' 카테고리의 다른 글
IE8/IE9 창 자동으로 강제 닫기 (0) | 2013.01.16 |
---|
a = 1234.5678;
Math.floor(a); //123 (버림)
Math.round(a); // 1235 (반올림)
Math.ceil(a); // 1235 (무조건 올림)
IE8/IE9 창 자동으로 강제 닫기 (0) | 2013.01.16 |
---|