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
var exports = exports || { }; | |
(function(ns) { | |
ns.createQueue = function(opts) { | |
var maxSize; | |
if (opts && typeof opts.maxSize === 'number') { | |
maxSize = opts.maxSize; | |
} |
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
var A = function(name) { | |
this.name = name; | |
}; | |
A.prototype.print = function() { | |
console.log(this.name); | |
} | |
/* | |
var init = function(c) { |
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
/* Found in one of router's HTML files */ | |
function encrypt(str) | |
{ | |
var result = ""; | |
var escaped; | |
escaped = escape(str); | |
for(i = 0; i < escaped.length; i++) | |
result += escaped.charCodeAt(i) - 23; |
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
module SimpleRL | |
open System | |
let world = | |
[| | |
"#### ####" | |
"# #### #" | |
"# #" | |
"## ##" | |
" # # " |
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
var Async = {}; | |
(function() { | |
// Constructor | |
this.makePromise = function(config) { | |
var Promise = { operation: config.operation | |
, args: config.args | |
, context: config.context | |
, then: then | |
}; |
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
var closureObj = {}; | |
(function() { | |
var one = function() { | |
console.log("One"); | |
}; | |
var two = function() { | |
console.log("Two"); | |
}; | |
var three = function() { | |
console.log("Three"); |