Today I have worked on my project in Java to make a refactoring of a class named TableUtil. First I decided to refactor it to Factory Method but I found out that TableUtil class depends on many small independent classes. These small classes are not so well implemented and I need of a new strategy for code refactoring. I realized that it’s very hard to refactor a core class because it depends from many small and independent classes. These independent classes could be named leaves and the core class could be named the root of the tree. So if you imagine the picture it’s very easy to start tackling with the complexity from the leaves instead of the root. Briefly we need to work on small steps from the periphery of the complicated code to the center of the problem!
Time is a great teacher, but unfortunately it kills all its pupils.
- Hector Berlioz
How does a project get to be a year late ?
… One day at a time.
– Excerpt from “The Mythical Month-Month”
Laziness: The quality that makes you go to great effort to reduce overall energy expenditure. It makes you write labor-saving programs that other people will find useful, and document what you wrote so that you don’t have to answer so many questions about it.
—Larry Wall
Great programmers can do more than just get their code to work, they can also build a foundation to allow their efforts to be extended.
- Paul W. Homer
Source : Paul W. Homer blog
Yestarday I read an interesting article regarding different constraints which every project manager should have in mind when he manages a project. According to “A Guide to the Project Management Body of Knowledge (PMBOK® Guide) – Fourth Edition” there are 6 constraints for every project (Schdeule, Resource, Scope, Risk, Budget, and Quality). Can you imagine how many possible decisions we have if every constraint has only ten levels of control? Yes, I can imagine they are 1 000 000. This result remember me the history of creator of the chess game who want’s from the king of Persia to put on the first square of the chess board one grain of wheat and after that to multiply by two for every next square until the last 64th square. The result of this operation was that the king would have been the poorest man in his kingdom if he give the wheat. So next time when you consider the best case scenarion have in mind this combinatorial explosion or you would suffer as king of Persia!
Writing programs in terms of the problem domain rather than in terms of lowlevel implementation details reduces your mental workload.
- Steve McConnell
I wonder how many great novelists have never read someone else’s work, how many great painters have never studied another’s brush strokes, how many skilled surgeons never learned by looking over a colleague’s shoulder…. And yet that’s what we expect programmers to do.
—Dave Thomas
Code as if whoever maintains your program is a violent psychopath who knows where you live.
—Anonymous
Any fool can write code that a computer can understand. Good programmers write code that humans can understand.
-Martin Fowler
In a hierarchy, every employee tends to rise to his level of incompetence.
—The Peter Principle