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
// YQL serves JSONP (with a callback) so all we have to do | |
// is create a script element with the right 'src': | |
function YQLQuery(query, callback) { | |
this.query = query; | |
this.callback = callback || function(){}; | |
this.fetch = function() { | |
if (!this.query || !this.callback) { | |
throw new Error('YQLQuery.fetch(): Parameters may be undefined'); | |
} |
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 events = require('events'); | |
exports.Promise = function () { | |
exports.EventEmitter.call(this); | |
this._blocking = false; | |
this.hasFired = false; | |
this._values = undefined; | |
}; | |
process.inherits(exports.Promise, events.EventEmitter); |
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
from itertools import permutations, imap, product | |
from datetime import datetime, timedelta | |
from random import random, choice | |
import string | |
basetime = datetime(2010,5,5) | |
airports = map(lambda a: ''.join(a), permutations(string.ascii_uppercase, 3)) | |
flights = [] | |
for i in xrange(1,500000): | |
td = timedelta( |
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
def hover | |
puts "hello" | |
end | |
NewerOlder