Skip to content

Instantly share code, notes, and snippets.

@LCamel LCamel/gist:1301166
Created Oct 20, 2011

Embed
What would you like to do?
var http = require("http");
function f() {
var s = Math.random();
for (i = 0; i < 100000; i++)
s += i;
return s;
}
function g() {
var s = Math.random();
for (i = 0; i < 1000000; i++)
s += i;
return s;
}
http.createServer(function(request, response) {
response.writeHead(200, {"Content-Type": "text/plain"});
response.write("f: " + f());
response.write("####");
response.write("g: " + g());
// f(function() { response.write("a");});
response.end();
}).listen(8888);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.