1  Why Python?

Python is a versatile programming language that is widely used in various fields, from web development to scientific computing. Here are some reasons why Python is a popular choice for beginners and professionals alike:

Figure 1.1: Top programming languages on GitHub (2024). GitHub is a popular platform for hosting and sharing code.

1.1 Python in the IEM Program

In the IEM program, you will work with several MILP solvers, such as Gurobi and CPLEX, which have Python APIs. You will also use Python libraries like NumPy, Pandas, and Matplotlib for data analysis and visualization.

1.2 Disadvantages

Python is not without its drawbacks. Here are some of the limitations of Python:

  • Slower than compiled languages like C++, Java. For performance-critical applications, Python may not be the best choice. However, Python can be optimized using libraries like NumPy and Cython. Also, there have been improvements in Python’s performance over the years.
  • Global Interpreter Lock (GIL) can limit the performance of multi-threaded applications. Threads consist of multiple tasks that run concurrently. The GIL prevents multiple threads from executing Python bytecodes simultaneously. This can be a bottleneck for CPU-bound applications that require parallel processing. However, the GIL does not affect I/O-bound applications, which spend most of their time waiting for input/output operations to complete.