diff options
1 files changed, 23 insertions, 0 deletions
| -rw-r--r-- | homework/81709/JSCompiler.SyntaxHighlighter/test/test.js | 23 |
diff --git a/homework/81709/JSCompiler.SyntaxHighlighter/test/test.js b/homework/81709/JSCompiler.SyntaxHighlighter/test/test.js new file mode 100644 index 0000000..537e59f --- /dev/null +++ b/homework/81709/JSCompiler.SyntaxHighlighter/test/test.js @@ -0,0 +1,23 @@ +/* +** This is a test function to demonstrate syntax highlighting! +*/ +function myFunction() { + var res = ""; + res = res +isNaN(123) + ": 123"; + res = res + isNaN(-1.23) + ": -1.23"; + res = res + isNaN(5-2) + ": 5-2"; + res = res + isNaN(0) + ": 0"; + res = res + isNaN('123') + ": 123 + "; + //oops! + res = res + isNaN(true) + ": true"; + res = res + isNaN(undefined) + ": undefined \ + nextString \ + "; + res = res + isNaN('NaN') + ": NaN 'Hell no'"; + res = res + isNaN(NaN) + ': NaN \\n \'; + res = res + isNaN(0 / 0) + ": 0 / 0 \ "; + + document.getElementById("demo").innerHTML = res; +} +//Cool, it works!
\ No newline at end of file |
