Digging Python
I dusted off my Raspberry Pi 2 today and looked around for some Python resources. I remembered seeing some documentation from the various vendors that sell the Pi that it’s great to learn Python on. I am pretty sure this is for kids to learn and seeing how I’m a professional developer this has to be a walk in the park right?
Learning a new anything requries you to check your ego at the door. No matter how proficient you are at similar skills you’re going to stumble at some point. That’s okay. I was able to complete all of the exercises but actually had to think a little bit on the very last exercise: compute the sum of all the digits of all the numbers from 1 to 1000.
This was an interesting exercise. In Java or JavaScript using a brute force method it would not be elegant at all. In Python I was able to do this in about 5 lines of code which were readable. So far I’m impressed with the Python language and how it seems to give developers a lot of convenience for pretty common tasks: iterating over lists, splitting strings with tokens, joining lists, and the different types of casts.
I’m hooked. Next up on my learning strategy: Learn Python The Hard Way.