2012-02-17 Pietro Martinelli coding horrors Reinventing the wheel: Collection.size() Original way to reinvent the wheel - by an examination of “Programming Fundamentals” 1234567891011public class MyContainer { private final Collection myBag; public int getBagSize() { int j = 0; for(int i = 0; i < this.myBag.size(); i++) { j++; } return j; }} Newer Never executed - Never tested Older Improper inheritance and light-hearted downcast