Bear Bibeault wrote:There is no such property as fillStyle.
Mark Spritzler wrote:"If I want to stick two completely different types into the same array it lets me."
Actually, interfaces are so powerful and gives us more abilities that you wouldn't get without them, so this is actually a plus for Java.
Bear Bibeault wrote:Part of good coding practice means following conventions. Naming a constructor init() isn't. A constructor should be a noun sand start with a capital letter. It describes what is being created.
Bear Bibeault wrote:Any function can be a constructor -- it's invoking the function with the new operator that makes two special things happen:
A new blank object is created The new object is implicitly "passed" to the construtor as the this parameter. (In other words, it becomes the function context.)
The prototype property of the constructor can be used to assign members to every object created through the constructor.