Created
August 31, 2011 10:05
-
-
Save eamodeorubio/1183228 to your computer and use it in GitHub Desktop.
Autoejecutable cuenta 0 a 100 sin usar bucles, condicionales o expresiones booleanas
This file contains hidden or 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
(function(max) { | |
var counter = 0 | |
, theEnd = function() { | |
console.log(max); | |
} | |
, count = function() { | |
console.log(counter); | |
counter++; | |
countOperations[counter] = count; | |
countOperations[counter % max](); | |
} | |
, countOperations = [theEnd]; | |
count(); | |
})(100); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment