Sitemap
A list of all the posts and pages found on the site. For you robots out there is an XML version available for digesting as well.
Pages
A flexible two-column Jekyll theme. Perfect for personal sites, blogs, and portfolios hosted on GitHub or your own server. Latest release v4.9.1
Python - no statistics, no fancy modules, just simple Python
Learn the essentials for working with Python.
Splash Page
Bacon ipsum dolor sit amet salami ham hock ham, hamburger corned beef short ribs kielbasa biltong t-bone drumstick tri-tip tail sirloin pork chop.
Posts
examples
unit00
How-to-Base-Python
Welcome to Base Python. Unit 00 explains how the course is organized, how to use the learning materials, and which requirements apply to you. Course at a Gl...
Deliverables
The course distinguishes between study requirements (Studienleistung) and examination requirements (Prüfungsleistung). Depending on your study program, you ...
Frequently Asked Questions
What is the expected workload for this course? This course awards 6 ECTS credits, corresponding to a total workload of approximately 180 hours. The workloa...
Submission Guidelines
This page describes the requirements for submitting the final project (Abschlussprojekt). Final Project Submission The final project is part of the study...
unit01
| LM | Introduction |
Python: A Versatile and Beginner-Friendly Language Introduction Python is a high-level, interpreted programming language created by Guido van Rossum, first ...
| LM | Jupyter |
Working with Jupyter (Uni Marburg Environment) Python can be used in many development environments such as Visual Studio Code, PyCharm, Thonny, or Jupyter. ...
| LM | Algorithm |
What Is an Algorithm? An algorithm is a finite sequence of clear, ordered instructions for solving a problem or completing a task. It specifies: where t...
| EX | Installing Libraries |
What are Libraries? In programming, libraries are collections of pre-written code that provide reusable functions, classes, and methods to perform common ta...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The questions highlight the key concepts of this unit and help prepare for the final...
unit02
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The questions highlight the key concepts of this unit and help prepare for the final...
unit03
Overview
In this unit, you’ll learn essential programming tools to process data and make decisions. Topics Strings: Functions and Methods Working with text ...
| LM | Introduction |
Strings are everywhere—from names to file paths. In this unit, you’ll learn how to use string functions and methods to work with text more effectively.
| LM | Logical Operators |
Logical operators in Python are used to combine multiple conditions and perform logical operations. These operators are fundamental for decision-making in yo...
| LM | Comparison Operators |
Comparison operators in Python allow you to compare values and determine their relationships. These operators are fundamental in making decisions and control...
| LM | Mathematical Operators |
Mathematical operators in Python allow you to perform basic arithmetic operations on numbers. These operations are fundamental in any programming language ...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The questions highlight the key concepts of this unit and help prepare for the final...
unit04
Overview
In this unit, you’ll explore how to control the flow of a Python program using conditional logic and error handling. Topics if statements Execute c...
| LM | Introduction to Conditionals |
Learn how to control the flow of your Python programs using conditional statements like if, elif, and else.
| LM | if Statement |
In Python, if statements are used to control the flow of a program by executing certain blocks of code only when specific conditions are met. The basic form ...
| LM | if and elif |
The elif statement in Python, short for “else if,” allows you to check multiple conditions in sequence. It provides a way to handle more than just two possib...
| LM | if, elif and else |
The else statement in Python is used to define a block of code that will execute if none of the preceding if or elif conditions are True. It acts as a defaul...
| LM | try/except |
try and except are used for error handling in Python. They help a program react to exceptions gracefully instead of crashing immediately. This makes programs...
| EX | Exercises |
Introduction This unit focuses on Python’s control flow structures, particularly using if, elif, and else. You will create small programs to practice decisi...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The questions highlight the key concepts of this unit and help prepare for the final...
unit05
Overview
In this unit, you’ll discover how Python handles structured data using built-in and library-based object types. You will explore different ways to store mult...
| EX | Exercises |
Introduction This unit covers Python’s data structures, including lists and data frames (using pandas). You will work through various tasks to build familia...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The questions highlight the key concepts of this unit and help prepare for the final...
unit06
Overview
Overview of Loops in Python In Python, loops allow you to execute a block of code repeatedly. The two main types are for-loops and while-loops. Knowing whic...
| LM | Introduction |
Loops let you repeat code without writing it multiple times. They help automate tasks, work with lists, and run code until a condition is met. Python has two...
| LM | FOR Loop in range() |
What are For-Loops? For-loops are a core structure in Python that repeat a block of code multiple times. They are ideal when the number of repetitions is kn...
| LM | FOR Loop in lists |
Why Use For-Loops with Lists and Tuples? For-loops are useful when working with lists and tuples, because they allow you to access each element in a structu...
| LM | While-Loops |
What is a While-Loop? A while-loop is a control structure that repeats a block of code as long as a condition is true. Use it when you don’t know in advanc...
| EX | Exercise For |
Introduction This unit includes loop-based challenges with logic, pattern recognition, and list updates. Task 1: FizzBuzz Variation Instructions: Write...
| KC | Knowledge Check |
Loops in Python The Knowledge Check is intended to support learning and self-assessment. The questions highlight the key concepts of this unit and help prep...
unit07
Overview
You will learn what a csv file is and how to use it in a dataframe.
| LM | Introduction |
Working with Files Working with files is essential when you want to read data from documents, save analysis results, or exchange information between program...
| LM | Import |
Importing CSV Data with pandas Reading tabular data into a DataFrame is a common task in data analysis. If your CSV file uses commas as separators, periods ...
| LM | Edit |
Working with CSV Data In this section, you’ll learn how to read, explore, and manipulate data from a CSV file using pandas. Download CSV file Import CSV...
| LM | Export |
Exporting CSV Data with pandas After data processing, you can save your DataFrame to a CSV file using to_csv(): df.to_csv("path/to/your/output_file.csv", s...
| EX | Exercises |
In-Class Tasks (20 Min): Working with Books CSV Use the online CSV file and follow the steps to explore the dataset using pandas. CSV URL: https://geomoer....
| KC | Knowledge Check |
1 Multiple Choice What is a CSV file? A) A compressed image format B) A text file used to store tabular data C) A Python program D) A database server S...
unit08
Overview
You will learn how to create simple visualizations in Python using matplotlib.
| LM | Introduction |
Why Visualizations? Visualizations help us understand data at a glance. They allow us to identify trends, compare groups, and reveal relationships that migh...
| LM | Installing Matplotlib |
Matplotlib is an external Python library. It must be installed in the same Python environment that your notebook or script uses. Check Whether Matplotlib Is...
| LM | Basic Functions |
Why Customize Plots? Adding titles, labels, and legends makes your plots easier to understand and more informative. It helps the audience quickly see what e...
| LM | Creating |
In Python, there are several libraries you can use to visualize charts and graphs. Here are some of the most popular options: Different Types of Plots in Ma...
| LM | Plotting Multiple Data |
Plotting Multiple Data Series on One Graph Sometimes you want to display several data series on the same plot to compare them easily. Example import matpl...
| LM | Essential Pandas Functions for Data Analysis & Plotting |
1. Essential Pandas Functions for Data Analysis & Plotting To create statistical diagrams with Matplotlib later on, students should be familiar with the...
| EX | Exercises |
Simple Visualization Practice Tasks These tasks are designed to help you practice simple data visualization in Python using Matplotlib. You will use a CSV f...
| KC | Knowledge Check |
1 Multiple Choice Which chart type is most suitable for showing the development of a value over time? A) Pie chart B) Line chart C) Bar chart D) Histogr...
unit09
Overview
Object-Oriented Programming (OOP) in Python Object-Oriented Programming (OOP) is a fundamental approach that allows you to structure your programs around ob...
| LM | Introduction |
Python supports object-oriented programming, and almost every value in Python is an object. OOP lets you: Group related data and functions together into ...
| LM | Class |
What is a Class? A class is like a blueprint for creating objects. It defines a set of attributes (characteristics) and methods (actions) that its objects (...
| LM | Instance variables vs. class variables |
Two kinds of data Data can belong to one object or be shared by the class. Instance variables Instance variables belong to one specific object. They are c...
| LM | Methods |
A method is a function that is defined inside a class and operates on objects (instances) of that class. Methods allow your objects to perform actions or re...
| LM | Inheritance in Object-Oriented Programming |
Inheritance is a fundamental concept in object-oriented programming (OOP). It allows one class to inherit attributes and methods from another class. The ...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The Knowledge Check is not graded. 1 Multiple Choice What is a class in object-...
| EX | Exercises |
Task In this exercise, you will model an animal using object-oriented programming. You will use instance variables for each animal and dictionaries for shar...
unit10
| EX | Exercise Solutions |
Solutions 1. Basic Data Types The false statement is G. A string cannot be concatenated with an integer using +. c = "Hello" number = 3 # c + number raise...
Overview
The Base Python course provides a solid foundation for understanding and using Python, one of the most popular and versatile programming languages today. Du...
| LM | Introduction |
Welcome to the Base Python course review section! This section is designed to help you refresh your skills, strengthen your confidence, and prepare you for ...
| LM | Basic Data Types |
Basic Data Types In Python, data types are the fundamental building blocks that define the nature of a value. The most common basic data types include: ...
| LM | Working with Strings and Simple Operators |
What are strings? Strings are sequences of characters, used to store and work with text data in Python. You can think of them as ordered collections of lett...
| LM | Conditionals |
Conditionals Conditionals allow your program to make decisions based on certain conditions. In Python, you use: if statements elif (else if) statement...
| LM | Collection Data Types |
Collection Data Types: Lists, Arrays, and DataFrames Collections store multiple related values. This course introduced Python lists, NumPy arrays, and panda...
| LM | Loops |
Loops Loops let you execute code repeatedly. In Python, the main loop types are: for loops: Iterate over a sequence (like a list or string) while loop...
| LM | Working with Files (CSV) |
Working with Files (CSV) Reading and writing files, especially CSV files, is crucial for data analysis and sharing results. In Python, you can use: The ...
| LM | Simple Visualisations |
Simple Visualisations Visualization is a key skill for communicating your data insights. In Python, you often use: matplotlib for creating plots and cha...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The Knowledge Check is not graded. 1 Multiple Choice Given: age = 25 price = 4...
| EX | Exercises |
1. Basic Data Types – “What is it?” Task: You have defined the following variables: a = 42 b = 3.14 c = "Hello" d = True e = [1, 2, 3] Question: ...
| KC | Knowledge Check |
The Knowledge Check is intended to support learning and self-assessment. The Knowledge Check is not graded. 1 Multiple Choice Given: age = 25 price = 4...
unit11
Overview
Unit 11 introduces the topic of Artificial Intelligence (AI) and shows how the Python skills you have learned form the foundation of modern AI systems. Arti...
| LM | Introduction |
Welcome to the Artificial Intelligence (AI) introduction section of the Base Python course. In this unit, you will explore what Artificial Intelligence is, ...
| LM | What is Artificial Intelligence? |
Artificial Intelligence (AI) refers to computer systems that are designed to perform tasks which normally require human intelligence. Such tasks include: ...
| LM | The Role of Data in Artificial Intelligence |
Data is a central foundation of machine-learning systems. Such systems need suitable data to learn patterns and to be evaluated. Rule-based AI can operate wi...
| LM | Python and Artificial Intelligence |
Python is one of the most important programming languages used in the field of Artificial Intelligence (AI) and data-driven applications. This does not mean...
| LM | Social Benefits and Risks of Artificial Intelligence |
Artificial Intelligence has a growing impact on society. It offers significant benefits, but also raises important social and ethical concerns. Understandin...
| LM | Reliable and Correct Programming with AI |
Artificial Intelligence can support software development, but it can also produce incorrect, incomplete, or misleading code. A central insight is: AI sy...
| EX | Exercises |
Comparing AI Answers Use two AI models that are available and approved for use in your course. Enter the same prompt into both models. Do not include person...
unit99
Spotlight
Spotlight: What’s Next? Congratulations — you have successfully completed the Base Python course! You now have a solid foundation in programming concepts l...