Features and benefits of using the Python programming language

Python is an easy-to-use, yet full-featured programming language that provides many more tools for structuring and maintaining large programs than shell. On the other hand, it handles errors better than C, and, being a very high-level language, has built-in high-level data types such as flexible arrays and dictionaries, which are time-consuming to implement efficiently in C.

Due to more general data types, Python is applied to a wider range of tasks than Awk and even Perl, at the same time many things in Python are done just as easily.

Python allows you to break programs into modules that can then be used in other programs. Python comes with a large library of standard modules that can be used as the basis for new programs or as examples when learning the language. Standard modules provide tools for working with files, system calls, network connections, and even interfaces to various graphics libraries.

Python is an interpreted language, which saves a significant amount of time usually spent on compilation. The interpreter can be used interactively, which allows you to experiment with the capabilities of the language, write program templates or test functions during bottom-up development. It is also handy as a desktop calculator. Python allows you to write very compact and easy-to-read programs. Programs written in Python are usually much shorter than the equivalent in C or C++ for several reasons:

high-level data types allow you to express complex operations with a single instruction;
grouping of instructions is performed by indentation instead of curly braces;
there is no need to declare variables;

Python is an extensible language: knowledge of C allows you to add new embedded functions or modules to perform critical operations with maximum speed or write an interface to commercial libraries available only in binary form. The Python language interpreter can be embedded in a program written in C and used as an extension or command language for that program. Python is currently used by tens of thousands of programmers worldwide, and the number of people using it is rapidly growing, doubling and tripling every year. Python attracts users for a number of reasons. It is used for program development and allows for much faster development than traditional languages like C, C++ or Java.

This language works equally well on Windows, UNIX, Macintosh, and OS/2, and can be used to easily develop small applications or scripts as well as to deploy large programs. Python offers access to a powerful and easy-to-use set of 29 graphical user interface tools. Traditional machine languages like C and Pascal share a number of characteristics, such as strict typing, basic types, complex (and usually long) loops, and the need for large amounts of code to perform relatively small tasks. Java is fairly new, but shares most of the characteristics included in this list. Programmers familiar with traditional languages will agree that the lack of strict typing makes Python easier to work with.

Python in comparison with other languages
There are many differences between Python and other languages, let’s list the main ones:

Memory management is fully automatic – no need to worry about allocating or freeing memory. There is no threat of an “unsafe reference”. Java is the only language offering such a concept.
Types are associated with objects, not variables. This means that a variable can be assigned a value of any type, and that (for example) an array can contain objects of different types. Traditional languages do not provide this feature.
Operations are usually performed at a higher level of abstraction. This is partly a result of the way the language is written and partly a result of the extensive standard code library that comes with Python.

These and other features of Python make deploying applications extremely fast. The performance of the created application depends on its features. Of course, for a numerical algorithm that performs simple integer arithmetic in a ‘for’ loop, it does not matter what language it is written in. But for an “average” application, the performance increase can be amazing. One drawback of Python, compared to most traditional languages, is that it is not a fully compiled language; instead, it partially translates the program to an internal form of bytecode, and this bytecode is executed by the Python interpreter.

However, in the long run – modern computers have so much unused computing potential that for 90% of applications, performance is related to the choice of language. Java also compiles to bytecode, but currently runs slower than Python in most cases. In addition, it is very easy to combine Python with modules written in C or C++, which can be used to increase the speed of programs in critical areas.