When we learned about inheritance and exceptions, I thought it was grade twelve all over again. Almost nothing has changed over the course of the year when it came to these topics in python. These problems are solved the exact same way as they were in Python 2.7, which I am quite familiar with. However, the first term of 108 was spent on very basic things(NOT Object Oriented) so inheritance was a good refreshing of memory. Because of such a long hiatus in using classes, I was quite pleased with the review of the syntax.
For me at least, recursion isn't exactly new either. That being said, the python language Danny is teaching is not too familiar to me and the extensive uses of list comprehension is quite extraordinary. Many examples were simple 1 line answers instead of the multiple nested loops that I'm used to. I guess this is being efficient, but pythonese is truly extraordinarily simple compared to the language of java. System.out.println was really a headache because of the lack of connection to the coder. Print(x) is much more simple and easy to understand as it shows a clear indication on what the code will do.
I had learned recursion in my previous year in high school as well. However, I did not put it into practice a lot since we were just mostly taught the theory behind it. It was nice to see a lot of practical uses that recursion had.
I am looking forward to next week's lectures where we hopefully continue learning about data structures, a more abstract view of computer science. I find this very interesting. I mean, recursion is cool and all but learning things the second time just isn't the same.
No comments:
Post a Comment