Wednesday, April 18, 2007

No compilation error

It's kind of weird that I got very few compilation errors for the whole day today. I worked on a small program that modifies our test data to add some extra information in it. I didn't code it quickly but it was surprisingly smooth. There were a few times that I had been coding for half an hour or even an hour. Then I compiled the code after so many code changes, and it compiled successfully! And many times, the code ran properly too!

Hm, maybe my SCJP study does help me to write Java programs more carefully. I remembered to add to catch exceptions on the PrintWriter before I compiled it today. I used to have the compiler complaining about it all the time.

Notes to self: It helps to first know what's the expected program behaviour, then think through and design it, then start coding. When coding, take the time to ensure a part is correct before moving on to the next part.

No comments: