Serenity Operating System
at hosted 17 lines 398 B view raw
1try { 2 assert(Math.ceil(0.95) === 1); 3 assert(Math.ceil(4) === 4); 4 assert(Math.ceil(7.004) == 8); 5 assert(Math.ceil(-0.95) === -0); 6 assert(Math.ceil(-4) === -4); 7 assert(Math.ceil(-7.004) === -7); 8 9 assert(isNaN(Math.ceil())); 10 assert(isNaN(Math.ceil(NaN))); 11 12 assert(Math.ceil.length === 1); 13 14 console.log("PASS"); 15} catch (e) { 16 console.log("FAIL: " + e); 17}