Friday, 31 January 2014

Week 4: Inheritance, Exceptions, and Recursion

The vast majority of struggles I have in CS are to do with syntax. I have enough reasoning to figure out exactly what my program needs to do and exactly how it can do that, however, I just don't know how to say it with the correct programming grammar.  For this reason, I had some minute struggles with this past week's labs and exercises.  

At first during the exercise, I learned that I had no idea how to write exceptions.  This caused a flurry of rereading and looking through class materials, as well as a brief scan of other student's questions posted to piazza until I understood that the word I was looking was "raise".  Then my program was fine, except that I misread the instructions and programmed the error to catch odd numbers instead of even numbers.  Luckily the automated report system can catch whenever I make such an error; I really can appreciate how helpful it is.  Other than that, the only thing I had to take time to get used to is the new formatting for the code.  We had a specific way of writing the docstring in CSC108 that I had to adjust slightly for CSC148.  But I do think I am now familiar with it and have made a successful transition.

During the lab this week, we switched partners and I got to work with a new student.  Things went quite well, and I learned a great deal about unittest and inheritance, especially the syntax (!!!) that is required when writing code involving inheritance.  All in all things went well with the lab.  I think that the exercises and labs are excellent teaching tools because I have learned the most through those experiences, since I actually have to think and immerse myself in the language of python when I am actually writing  program.  That, at least for me, has been a very effective way to learn.  Now, I'm just looking forward to the somewhat daunting task of completing the assignment, and with that I am signing off for this week.

3 comments: