Skip to content

Instantly share code, notes, and snippets.

@elsassph
elsassph / poop.js
Last active October 18, 2021 13:45 — forked from edankwan/poop.js
Array.prototype.poop = function() {
this.pop();
// return nothing, it's poop
}
Array.prototype.shit = function() {
this.shift();
// return nothing, it's poop
}
@elsassph
elsassph / 10squares.hx.js
Created December 30, 2011 09:49 — forked from xitij2000/10squares.hx.js
haXe code to print squares of first 10 numbers.
Main.main = function() {
js.Lib.document.write(Main.square(10).join(","));
}
Main.square = function(n) {
var result = [];
var _g = 0;
while(_g < n) {
var i = _g++;
result.push(i * i);
}