Python tasks
Every task in one place. Pick a mode, a topic or a concept to practise.
Every task of the course, from quick understanding checks to exam-style problems.
13 tasks
- Predict the outputElementaryWhich branch runs?Conditions · Theory and practiceComparisons: ==, !=, <, >=Several branches: elif
- Fix the programElementaryPositive, negative or zeroConditions · Theory and practiceReading numbers from inputTwo branches: if – elseSeveral branches: elif
- Write a programBasicA grade from a testConditions · Programming challengesComparisons: ==, !=, <, >=Several branches: elif
- Write a programElementaryA calculatorConditions · Programming challengesArithmetic operatorsSeveral branches: elifNested conditions
- Write a programIntermediateParking feeConditions · Programming challengesFormatting output: sep, end, f-stringsInteger division and remainder: // and %Two branches: if – elseSeveral branches: elif
- Write a programElementaryThe largest of threeFunctions · Programming challengesSeveral branches: elifParameters and argumentsReturn values: return
- Write a programElementaryBMI calculatorGraduation exam preparation · StringsReading numbers from inputFormatting output: sep, end, f-stringsArithmetic operatorsSeveral branches: elif
- Write a programElementaryCaesar cipherGraduation exam preparation · StringsInteger division and remainder: // and %Several branches: elifLooping over a stringCharacters and codes: ord() and chr()
- Write a programElementaryQuadratic equationGraduation exam preparation · StringsReading numbers from inputArithmetic operatorsSeveral branches: elifStandard modules: math, random
- Small projectElementaryRock, paper, scissorsGraduation exam preparation · StringsLogical operators: and, or, notSeveral branches: elifReturn values: returnStandard modules: math, random
- Write a programElementaryVowel or consonantGraduation exam preparation · ListsSeveral branches: elifwhile loopsString methods: upper, find, replace, …Membership: in
- Write a programElementaryColoured raysGraduation exam preparation · Graphics with tkinterSeveral branches: elifDefining and calling functionsDrawing on a canvas (tkinter)Events: clicks and keys
- Small projectElementaryGuess a number from 1 to 50Graduation exam preparation · Exceptions (try – except)Several branches: elifwhile loopstry – exceptValidating inputStandard modules: math, random