Sunday, September 18, 2011

Post 3 or Pulling an All Nighter

The week before last in my Object Oriented Programming class we were assigned homework that was due the following Thursday. It was 6 problems long and two only had to be written, and one were allowed to work with a partner. Seemed simple enough. I could not have been more wrong... The first three problems weren't all that bad. The first two were written problems and were done within a few minutes, and the third was a simple calculation program. It was the last three that were the trouble-makers. With the previous program problem were given the first half of the program by the professor and simply had to plug-in the rest. The others, besides 4, required us to do the ENTIRE program from scratch starting from Square 1. If I made any error in either half of the programming then the entire thing would not run  properly and I would have to scour back over the code and attempt to discern what the problem was. Sure enough I did something wrong on every single one... On problem #4  the goal was to create a function that calculated the decimal equivalent of a fraction. Seems simple enough seeing how it is basic math. It wasn't as easy as it sounds. I typed out what I believed to be the correct coding and attempted to run it. The first thing I saw was that there was an error. I looked back over the program and could not find what was wrong. I tried running it multiple times and  tried fixing the code  ways trying to correct the code, but nothing seemed to work. On what was to be my final pass over the code I found my mistake. When I found out what I had done wrong it annoyed me to no end. I had forgotten one, single, solitary parentheses.... In programming the smallest of mistakes can ruin the entire thing. The last two problems had similar issues. The "little" errors kept me and my friend Matt up all night and we even considered switching majors around 3 in the morning. At one point we went to Whataburger just so we would not destroy our computers in frustration. Eventually we fixed our mistakes and turned them in. However, we got very little sleep that night and promised to keep each other awake in our classes the following day. We even vowed to never allow something like happen ever again. At least not anytime soon...

No comments:

Post a Comment