Serenity Operating System
at hosted 16 lines 440 B view raw
1try { 2 assert(Math.tan(0) === 0); 3 assert(Math.tan(null) === 0); 4 assert(Math.tan('') === 0); 5 assert(Math.tan([]) === 0); 6 assert(Math.ceil(Math.tan(Math.PI / 4)) === 1); 7 assert(isNaN(Math.tan())); 8 assert(isNaN(Math.tan(undefined))); 9 assert(isNaN(Math.tan([1, 2, 3]))); 10 assert(isNaN(Math.tan({}))); 11 assert(isNaN(Math.tan("foo"))); 12 13 console.log("PASS"); 14} catch (e) { 15 console.log("FAIL: " + e); 16}