Introduction to Python
Examine the importance and useability of the Python language in the modern era.
We'll cover the following
Python is a high-level programming language created by Guido van Rossum—fondly known as the benevolent dictator for life. Python was first released in 1991. Today, Python interpreters are available for many operating systems, including Windows and Linux. Python programmers are often called Pythonists or Pythonistas.
Reasons for popularity
There are several reasons for Python’s popularity:
-
Cost:
- Python is free to use and distribute and is supported by the community.
- Python interpreter is available for every major platform.
-
Software quality:
- It’s better than traditional and scripting languages.
- It’s readable code, therefore reusable and maintainable.
- There’s support for advanced reuse mechanisms.
-
Developer productivity:
- It’s much better than statically typed languages.
- It uses much smaller code.
- There’s less to type, debug, and maintain.
- There are no lengthy compile and link steps.
-
Program portability:
- Python programs run unchanged on most platforms.
- Python runs on every major platform currently in use.
- Porting a program to a new platform usually only requires cut and paste. This is true for GUI, DB access, web programming, OS interfacing, directory access, etc.
-
Support libraries:
- There is strong library support from text pattern matching to networking.
- There’s a vast collection of third-party libraries.
- There are libraries for website construction, numeric programming, game development, machine learning, etc.
-
Component integration:
- It can invoke C, C++ libraries, and Java components.
- It can communicate with frameworks such as COM, and .NET.
- It can interact over networks with interfaces like SOAP, XML-RPC, CORBA.
- With appropriate glue code, Python can subclass C++, Java, and C# classes, thereby extending the reach of the program.
- It’s popularly used for product customization and extension.
-
Enjoyment:
- It’s easy to use.
- There’s a built-in toolset.
- Programming becomes more of a pleasure than work.
What sets Python apart?
-
Powerful:
- Dynamic typing.
- No variable declaration.
- Automatic allocation and garbage collection.
- Supports classes, modules, and exceptions.
- Permits componentization and reuse.
- Powerful containers—lists, dictionaries, tuples, etc.
-
Ready-made stuff:
- Support for operations like joining, slicing, sorting, mapping, etc.
- Powerful library.
- Large collection of third-party utilities.
-
Ease of use:
- Type and run.
- No compile and link steps.
- Interactive programming experience.
- Rapid turnaround.
- Programs are simpler, smaller, and more flexible.
Python is used for multiple purposes. These include:
- System programming
- Building GUI applications
- Internet scripting
- Component integration
- Database programming
- Rapid prototyping
- Numeric and scientific programming
- Game programming
- Robotics programming
Who uses Python today?
Many organizations use Python for varied purposes. These include:
- Google: Web search system
- YouTube: Video sharing service
- BitTorrent: Peer to peer file sharing system
- Intel, HP, Seagate, IBM, Qualcomm: Hardware testing
- Pixar, Industrial Light, and Magic: Movie animation
- JP Morgan, Chase, UBS: Financial market forecasting
- NASA, FermiLab: Scientific programming
- iRobot: Commercial robot vacuum cleaners
- NSA: Cryptographic and intelligence analysis
- IronPort: Email servers