Python 101 for Product Managers
Learn the basics of Python with Devetry.
This presentation and additional commentary are ideal for product managers wanting to understand what Python is, how it’s used, and why your development team raves about it. For the text version, keep scrolling.
The following presentation was transcribed from “SQL and Python for Product Managers” webinar, presented by Colorado Product Meetup and Devetry senior software engineer, Brian Schiller. It has been edited for clarity.
As a product manager, it can be incredibly helpful to understand the basics of the programming languages and tools that your team uses each day. So if your team currently uses Python, here is general information that can help you communicate with your development team.
What is Python?
Python is a mature programming language (four years older than Java!) and “the fastest-growing major programming language today” according to Stack Overflow.
A lot of its recent growth is attributable to its use in data science. It has been strongly adopted by the data scientist community and since data science is growing quickly, Python is also growing.
Fun fact, Python’s name took inspiration from Monty Python’s Flying Circus.
What Does Python Look Like?
We will be looking at three examples of Python code:
- A simple example
- An example using Django
- An example using Sklearn
A Simple Example
Even if you’ve never seen Phyton before, that’s okay. You will still be able to read it because it was specifically designed with a focus on readability. See if you can understand what the image below says:
The above image is a function to accept a date and then figure out the nearest Monday. If it is Friday or later, then next Monday is closer. Otherwise, the previous Monday is closer.
Here’s what Python looks like in Django, a web programming framework.
Here is a machine learning example.
In this case, we’re making a support vector machine to classify and predict handwritten digits. The machine accepts a picture of a handwritten number (possibly an envelope sent through the mail) and it can tell you what number you’ve written. The code is short, especially considering how powerful it is.
It uses the machine learning model where humans tell the program which numbers are which at first. Then, once the program has enough data, humans stop telling it and see if the machine can identify numbers on its own.
What Are Python’s Values?
You might not know that programming languages have values, but they do! And usually, they take on the value of their creators. Here’s what Python’s founder, Guida van Rossum had to say about Python’s values.
“You primarily write your code to communicate with other coders, and, to a lesser extent, to impose your will on the computer.” —Guido van Rossum
Another Python value is that programmer’s time is more expensive than servers. Therefore, the language is optimized to be easy to understand and write. You can express a lot of ideas with it. However, it’s not necessarily the fastest language.
Another positive — batteries included. In other words, Python’s standard library has a lot of functions that are ready to use. And if the standard library doesn’t have it, there are many open-source packages that support your developer’s needs.
What’s Python Great For?
Web Programming: Instagram, Pinterest, and Dropbox are all written in Python. In fact, Instagram is famously the most popular and optimized Django site in existence.
Data Science & Machine Learning: There are a lot of powerful libraries like Pandas, Numpy, Scikit-learn, and Tensorflow (deep learning).
ETL, “Extract Transform Load” Workflows: Python tends to make a good “glue” language. It doesn’t get in the way. It’s flexible and quick to develop, but robust enough to support tests, modules, other things you’d expect from a “real” language to allow you to grow. As a comparison, there are some languages, (for example, Bash) where you can get overwhelmed with complexity.
Teaching: Python makes a great first language to learn because it’s simple to read and write. If you’re interested in learning the basics of Python, start here.
Overall, Python is a good default choice for most things. And for the few things that aren’t, you can hook Python into C++ whenever true performance is needed. Even early-stage Google adopted an attitude of “Python where we can, C++ where we must.”
What’s Python Not Great For?
There are a handful of things your development team probably won’t use Python for, including
- Graphical user interfaces (GUIs) that you expect a user to install on their computer
- Real-time systems like high-frequency trading, internet routers, or automated driving systems. Python won’t be fast enough for these millisecond reactions and confirmations
- Embedded systems or IoT (robotics, pacemakers, video game consoles)
What’s this Python 2/3 Thing I’ve Heard About?
In late 2019, Python had a rocky transition from version 2 to version 3 which confused some product managers and teams about which version is best to use.
Today, you should use Python 3. Python 2 is end-of-lifed and will not receive security fixes as of January 1st, 2020. It is still around because many operating systems rely on it for “glue” code, but eventually, systems will need to make the switch or face potential security issues.
If you’re a product manager, you don’t need to know the minutia of Python, but understanding the basics can help you communicate with your development team and comprehend what the code is doing on the backend.
Download the Product Manager’s Guide to Roadmaps
- Please complete this required field.
- [ ]Product
- [ ]Engineering
- [ ]Marketing
- [ ]HR
- [ ]Sales
- [ ]Other
Receive once-a-month technology and product trends from the Devetry blog
You can unsubscribe from these communications at any time.
By clicking submit below, you consent to allow Devetry to store and process the personal information submitted above to provide you the content requested.