Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function run_tests() {
- console.assert(abs(0) == 0, "abs(0) == 0");
- console.assert(abs(1) == 1, "abs(1) == 1");
- console.assert(abs(-1) == 1, "abs(-1) == 1");
- console.assert(1/0 == 1/abs(-0), "1/0 == 1/abs(-0)");
- console.assert(1/-0 != 1/abs(-0), "1/-0 != 1/abs(-0)");
- }
- run_tests();
Add Comment
Please, Sign In to add comment