Python programming essentials
A readable, general-purpose language widely used in data science, web development, automation and AI.
Edited by Alex C, EduAlx · Sources cited below
Explanation
Created by Guido van Rossum (first released 1991). Features: dynamic typing, indentation-based blocks, lists, dictionaries, comprehensions, functions as objects and a huge standard library. NumPy, pandas, scikit-learn and PyTorch make it the leading language for data and AI.
Example
Code
import pandas as pd
df = pd.read_csv('sales.csv')
print(df.groupby('region')['amount'].sum().sort_values(ascending=False))
How it works, step by step
- Write code in .py files or notebooks
- Interpreter compiles to bytecode
- Bytecode runs on the Python VM
- Libraries extend capabilities
Open the interactive page with diagrams →
People behind it
- Guido van Rossum (b. 1956), Computer science, Netherlands: Created the Python programming language (released 1991).
References
- G. van Rossum, F. L. Drake, The Python Language Reference, Python Software Foundation (docs.python.org).
Textbooks
- Structure and Interpretation of Computer Programs, Harold Abelson, Gerald Jay Sussman (MIT Press, 2nd ed. 1996). Classic on programming and abstraction.
Related topics
RecursionTesting and debuggingClustering and unsupervised learningHuman–computer interaction and usabilityDecision trees and ensemble methodsError-detecting and error-correcting codesReinforcement learningAlgorithms and Big-O complexityNatural language processingSorting algorithms (quicksort, mergesort, heapsort)