From online stores to a NASA rover: where is Python used and why should you study it in 2022
Python — what is this programming language? Why is it popular today and in what areas is it used? EPAM Lead Software Engineer, Yury Zaitsev, answers these and other questions below specifically for the Anywhere Club blog.
What is Python?
— Simply put, Python is a high-level programming language in which you can write almost everything. Python has been around for a while. The first outlines of what would become Python appeared in 1989, and Python 1.0 first saw the light of day in 1994. To be clear, this was very different from Python 2.0, which was released in 2000. In version 2.0, Python really hit its stride, and became a very popular programming language that developed rapidly. The current version, Python 3.0, was released in 2008.
What is the Python programming language for?
— In theory, the Python language can be used in any situation in which a programming language is needed: from developing a simple online store to a NASA rover. Truly. The Perseverance Ingenuity rover drone software was developed using F Prime. F Prime is a multi-component spacecraft modeling and software development framework created by NASA. It is written in C++ and Python. Most of it, of course, is in C++, but about 25% of it is still Python. In reality, though, it is not always advisable to use Python.
What is Python good for?
— Scope of Python — the areas in which Python is a superior tool are various and diverse. I suggest that the main areas in which it stands out are as follows:
Development of back-end web applications
These are online stores, online games, and streaming video services; examples include Django, FastApi, and Flask.
Solving scientific and near-scientific problems such as calculations, data analysis, and visualization.
This category includes things like genome analysis and the calculation of the flight paths of bodies in space, implemented through tools such as Pandas, jupyter, and Plotly.
Applications like face recognition, document recognition, and sales forecasting benefit from Python’s strengths. TensorFlow, Keras, PyTorch have proven themselves in this category.
Business processes, manufacturing, and smart home applications using AirFlow and Luigi.
This includes on-board computers in vehicles and robot vacuum cleaners. You can find details here: MicroPython.
The downsides of Python are harder to identify. There are no bad programming languages, but there are misuses. If you try to come up with one downside, it will likely be speed. Out of the box, CPython is significantly inferior in performance to compiled languages like C, because it is more high-level.
- High speed is not always needed.
- Popular libraries for data processing where performance is important usually use C-extensions and run at nearly the speed of C.
- Solutions like Cython, Numba, and PyPy introduce certain limitations, but they can greatly improve performance.
What kinds of things is Python not well-suited for and when is it better to choose a more appropriate tool?
Developing front-end web applications
Projects like Pyodide allow you to execute Python source code in abrowser via WebAssembly, but so far this is more of a hobbyist activity than a professional approach.
Frameworks like Kivy and BeeWare make it possible to develop full-fledged applications for Android and IOS, but doing so is not very convenient and this is not accepted in the industry.
Although there are game engines that support Python (Panda3D, Сocos2d, PyGame), C++ is better for AAA. It is, however, quite possible to write a visual novel using Python.
Why is Python popular?
Which large companies use Python today?
A huge number of companies around the world use Python. Some of the largest and most recognizable include the following:
- Google uses Python as one of its main programming languages, Microsoft actively uses it for web services, and Amazon uses it everywhere.
- Dropbox, Spotify, Instagram, and Reddit are all mostly written in Python.
- Netflix and Uber are not fully written in Python, but they actively use it.
- In games such as World of Tanks and EVE Online, the server part was written in Python.
Should I start learning Python in 2022?
— Python is now more popular than ever. Last year, it was at the top of the TIOBE index, overtaking C and Java. It is being actively developed, the syntax is expanding, and the “problems” often associated with Python, such as poor performance, are gradually being solved. There are also more and more open libraries in PyPI.
How long does it take to learn Python?
— It will take 3-4 months to learn the basics. Then, it is helpful to work “on the hook” for 3-6 months to see how everything works in practice.
What do you need to do to get started with Python?
— Python is hard not to like: it is a very concise and simple language, it is written quickly, and it has a lot of “batteries”. Plus, if you ever find yourself getting bored in your current position, while continuing to use Python you can transition to work as a test automation engineer, a machine learning engineer, and even a data analyst.
You can learn more about Python in the IT Beard Shorts issue on the Anywhere Club YouTube channel.
Have a desire to discuss Python? Go in Discord.