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
== PRINTER TEST PAGE = 1/1 == | |
;\ | |
|' \ | |
_ ; : ; | |
/ `-. /: : | | |
| ,-.`-. ,': : | | |
\ : `. `. ,'-. : | | |
\ ; ; `-.__,' `-.| | |
\ ; ; ::: ,::'`:. `. |
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
B = (f) -> (g) -> (h) -> f (g h) | |
M = (f) -> f f | |
K = (f) -> (g) f | |
Y = (f) -> M (B f) M |
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
(function () { | |
var root = this, | |
previousDollar = root["$"]; | |
var $ = function (it) { | |
return document.getElementById(it); | |
}; | |
root.baobob = root["$"] = $; |
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
class TwoByTwoMatrix | |
constructor: ([[@a, @b], [@c, @d]]) -> | |
toString: -> "[#{@a} #{@b}\n #{@c} #{@d}]" | |
determinant: -> (@a * @d) - (@b * @c) | |
inverse: -> | |
D = @determinant() | |
new TwoByTwoMatrix [[@d/D, -@b/D], [-@c/D, @a/D]] | |
alert new TwoByTwoMatrix([[1, 2], [3, 4]]).inverse().toString() |
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
<a href="data:text/html,plain;%3C!DOCTYPE%20html%3E%3Chtml%3E%3Chead%3E%3Ctitle%3EOMG!%3C%2Ftitle%3E%3Cscript%3Ewindow.onload%3Dfunction()%7BsetInterval(function()%7Bvar%20a%3Ddocument.body.style%3Ba.background%3D%22%23%22%2Bc(0%2C16777215).toString(16)%3Ba.fontSize%3Dc(10%2C100)%2B%22px%22%3Ba.padding%3Dc(10%2C125)%2B%22px%22%3Bvar%20b%3Dc(5%2C10)%3Bfor(var%20d%3D%22A%22%2Ca%3D0%3Ba%3Cb%3B%2B%2Ba)d%2B%3D%22A%22%3Bdocument.body.innerHTML%3Dd%7D%2C50)%7D%3Bfunction%20c(a%2Cb)%7Breturn%20a%2BMath.floor(Math.random()*(b-a))%7D%3B%3C%2Fscript%3E%3Cbody%20style%3Dcolor%3Awhite%3E">click here 4 fun!!</a> |
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
inAbout = (n) -> new -> | |
@milliseconds = (f) -> setTimeout f, n | |
@seconds = (f) -> setTimeout f, n * 1000 | |
every = (n) -> new -> | |
@milliseconds = (f) -> setInterval f, n | |
@seconds = (f) -> setInterval f, n * 1000 | |
console.log "starting!" | |
inAbout(3).seconds -> |
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
Number::toRadians = -> (@ * Math.PI) / 180 | |
Number::toDegrees = -> (@ * 180) / Math.PI | |
Array::product = -> @reduce (a, e) -> a * e | |
Array::sum = -> @reduce (a, e) -> a + e | |
Array::zip = (args...) -> ((args...) -> | |
longest = args.reduce ((a, b) -> (if a.length > b.length then a else b)), [] | |
longest.map (_, i) -> args.map (array) -> array[i])(@, args...) |
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
/* recursive version | |
*/ | |
var M = function (f) { return f(f); } // Mockingbird function | |
range = M(function (f) { | |
return function (min, max) { | |
return min === max ? [min] : [min].concat(f(f)(min + 1, max)); | |
} | |
}); |
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
/* SEMICOLON2.js | |
Copyright 2012 Jack Willis */ | |
(function () { return ;;; }).call(this); |
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
Number.prototype.superfactorial = function() { | |
var a, e, d, b, c; | |
d = 1; | |
for(a = b = 2;2 <= this ? b <= this : b >= this;a = 2 <= this ? ++b : --b) { | |
for(e = c = 2;2 <= a ? c <= a : c >= a;e = 2 <= a ? ++c : --c) { | |
d *= e | |
} | |
} | |
return d | |
}; |
NewerOlder