The following exercises are designed to help you practice the skills you’ve learned in the Get Started with Python Programming learning path on Microsoft Learn. Each exercise is self-contained and can be completed independently, but they are best used in conjunction with the corresponding modules on Microsoft Learn.
Exercises
Create a personalized greeting
Level: 100 | Duration: 15 minutes
Write a Python program that uses print(), input(), and f-strings to display a personalized greeting message.
Calculate a student’s GPA
Level: 100 | Duration: 20 minutes
Write a Python program that stores student grades as variables, performs arithmetic to calculate a GPA, and accepts scores as user input using type conversion.
Create a personalized banner app
Level: 100 | Duration: 25 minutes
Set up a Python project in Visual Studio Code, install a package with pip, and use GitHub Copilot to build a banner app that greets the user.
Create a rock, paper, scissors game
Level: 100 | Duration: 30 minutes
Build a rock, paper, scissors game in Python that uses comparison operators, if/elif/else conditional logic, and logical operators to determine the winner.
Create a Guess the Number game
Level: 100 | Duration: 25 minutes
Write a Python program that uses a while loop, conditional logic, and break to run an interactive Guess the Number game.
Build a coffee shop order tracker
Level: 100 | Duration: 25 minutes
Write a Python program that uses a dictionary of menu items, a list to track a customer’s order, and loops to print a formatted receipt.
Build a to-do list
Level: 100 | Duration: 25 minutes
Write a Python program that saves and loads tasks from a text file so a to-do list persists between runs.
Create a calculator
Level: 100 | Duration: 25 minutes
Write a Python program that uses functions with parameters and return values to build a simple interactive calculator.
Note: While you can complete these exercises on their own, they’re designed to complement modules on Microsoft Learn; in which you’ll find a deeper dive into some of the underlying concepts on which these exercises are based.