Review of "Learning Python: Types and Operations"

 Review of

Learning Python by Mark Lutz

Written by Ansh Singh


        Programming is found anywhere you look. Cars, phones, rockets, cameras, and even the laptop I use to write these blog posts. I believe that computer science and programming is the most influential career path right now considering the state of technology advancement. It seems that every year new technology appears that changes the way we think of programming altogether. Eventually, a technology breakthrough will come about and affect the world entirely. The era we are currently in is the internet era, an online world that allows instant communication from anywhere and everywhere. It is the ability to exchange information faster than ever and connects the world in a way never seen before. You can find and do everything on the internet. It is what changed this world so drastically and is what keeps our youth stuck to their phones. The internet, as is almost everything, is made up of billions maybe even reaching trillions of lines of code. One of these programming softwares in this huge web of statistics and information is Python. Python specializes in algorithms and data manipulation. For this post, we will look at Part II, Chapter 4 of “Learning Python” by Mark Lutz.

        In this chapter, simply put, we learn how to do things with stuff. Things here refer to operations like addition and subtraction, and stuff refers to the objects which we perform these operations on. Some of the main things we learn in this chapter are numbers, strings, lists, dictionaries, tuples, files, and other core types. For this post we will focus on numbers and lists.

        Numbers are fairly straightforward. Python’s core objects set includes the usual suspects: integers, floating-point numbers, and more exotic numeric types. Python also follows the normal mathematical operations with addition being +, multiplication being *, exponentiation being **, etc. It’s honestly simple; when you want the program to execute an operation, you use one of these symbols to do so.

        Lists are ordered collections of typed objects. Lists technically have no size, so you can use it for organization or any other purpose. When you type a list, you assign it to a name-reference. For simplicity, let's say this is what we wrote in our program:

L = [123, ‘spam’, 1.23]

        This list has three different-type objects: an integer, a string, and a floating-point number. Because this is a sequence, all sequence operations can be executed on this list. For example, we can index, slice, and so on, just as we could do to strings. Here is a diagramed system of this:



        As you can see, Mark Lutz goes into great detail about what you can do with just a program and a language. Mark Lutz and “Learning Python” is a great way to learn Python for beginners and more knowledgeable people alike, as he teaches readers about his methods of solving problems in a new fashion. If you are interested in programming and python, I strongly recommend this book to you even if you are a more experienced programmer.












Comments

  1. Great blog Ansh! You made some great points at the beginning about the influence of code and technology on modern society. A basic level of coding knowledge is a vital tool with many applications. This book seems like it would be a great way to familiarize myself with the python coding language. Thanks for the recommendation!

    ReplyDelete
  2. This review helps give the basic parts of python, which I think is a good way to encourage people that started coding by giving some knowledge in the subject. Its true that there needs to be way more programmers, and your review would help those who don't know where to start.

    ReplyDelete

Post a Comment