: )
var dmn = dmn || {} dmn.Speaker = function(name, outputObject, outputMethodName) { this.name = name; this.outputObject = outputObject || console; this.outputMethodName = outputMethodName || "log"; this.say = function(message) { this.outputObject[this.outputMethodName](message); } } var p = ( dmn.Greeter = function(name, outputObject, outputMethodName, salutation) { dmn.Speaker.call(this, name, outputObject, outputMethodName); this.salutation = salutation || "Hello,"; } ).prototype = new dmn.Speaker; p.greet = function(e) { this.say(this.salutation + " " + e.name); } var prog = new dmn.Greeter("Program", window, "alert"); var world = new dmn.Speaker("World"); prog.greet(world);
DFTBA
"To achieve great things, two things are needed:
a plan and not quite enough time." — Leonard Bernstein
"The computer is incredibly fast, accurate, and stupid.
Man is unbelievably slow, inaccurate, and brilliant.
The marriage of the two is a force beyond calculation." — Leo Cherne (maybe)