Created
January 26, 2015 11:34
-
-
Save joews/dd707ee71c322081ba42 to your computer and use it in GitHub Desktop.
// source http://jsbin.com/fewayu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>JS Bin</title> | |
</head> | |
<body> | |
<script id="jsbin-javascript"> | |
// | |
// My first attempt at a JS Quine (a program that prints itself) | |
// | |
// (T = function () { document.write('(T = ' + this.toString() + ').call(T)') }).call(T) | |
/* output: | |
(T = function () { document.write('(T = ' + this.toString() + ').call(T)') }).call(T) | |
*/ | |
// shorter | |
// (space after function is always present in output) | |
(S=function (){document.write('(S='+S+')()')})() | |
/* | |
(S=function (){document.write('(S='+S+')()')})() | |
*/ | |
</script> | |
<script id="jsbin-source-javascript" type="text/javascript">// | |
// My first attempt at a JS Quine (a program that prints itself) | |
// | |
// (T = function () { document.write('(T = ' + this.toString() + ').call(T)') }).call(T) | |
/* output: | |
(T = function () { document.write('(T = ' + this.toString() + ').call(T)') }).call(T) | |
*/ | |
// shorter | |
// (space after function is always present in output) | |
(S=function (){document.write('(S='+S+')()')})() | |
/* | |
(S=function (){document.write('(S='+S+')()')})() | |
*/</script></body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// My first attempt at a JS Quine (a program that prints itself) | |
// | |
// (T = function () { document.write('(T = ' + this.toString() + ').call(T)') }).call(T) | |
/* output: | |
(T = function () { document.write('(T = ' + this.toString() + ').call(T)') }).call(T) | |
*/ | |
// shorter | |
// (space after function is always present in output) | |
(S=function (){document.write('(S='+S+')()')})() | |
/* | |
(S=function (){document.write('(S='+S+')()')})() | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment