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.
23 tasks
- True / falseBasicA sum from input?Input and output · Theory and practiceInput with input()Reading numbers from input
- Fix the programElementaryThe area of a rectangleInput and output · Theory and practiceReading numbers from inputArithmetic operators
- Write a programBasicSum and average of three numbersInput and output · Programming challengesReading numbers from inputFormatting output: sep, end, f-strings
- Write a programBasicPrice after a discountInput and output · Programming challengesReading numbers from inputFormatting output: sep, end, f-strings
- Write a programBasicTwo numbers reversedInput and output · Programming challengesInput with input()Reading numbers from inputFormatting output: sep, end, f-strings
- Write a programIntermediateA price tableInput and output · Programming challengesReading numbers from inputFormatting output: sep, end, f-strings
- Complete the codeElementaryIs the number even?Operators · Theory and practiceReading numbers from inputInteger division and remainder: // and %Comparisons: ==, !=, <, >=
- Fix the programElementaryPositive, negative or zeroConditions · Theory and practiceReading numbers from inputTwo branches: if – elseSeveral branches: elif
- Complete the codeElementaryThe sum from 1 to nLoops · Theory and practiceReading numbers from inputfor loops and range()Counting and summing in a loop
- Write a programElementaryBMI calculatorGraduation exam preparation · StringsReading numbers from inputFormatting output: sep, end, f-stringsArithmetic operatorsSeveral branches: elif
- Write a programElementaryThe Fibonacci sequenceGraduation exam preparation · StringsVariables and assignmentReading numbers from inputfor loops and range()
- Write a programIntermediateMind readerGraduation exam preparation · StringsReading numbers from inputInteger division and remainder: // and %while loopsReturn values: returntry – except
- Write a programElementaryQuadratic equationGraduation exam preparation · StringsReading numbers from inputArithmetic operatorsSeveral branches: elifStandard modules: math, random
- Write a programBasicEntered values reversedGraduation exam preparation · ListsReading numbers from inputwhile loopsSlicingList methods: append, pop, remove, …
- Write a programElementaryTime in secondsGraduation exam preparation · The while loopReading numbers from inputFormatting output: sep, end, f-stringsInteger division and remainder: // and %while loops
- Write a programBasicNumbers without 3, 7 and 14Graduation exam preparation · The while loopReading numbers from inputLogical operators: and, or, notThe if statementwhile loops
- Write a programBasicEven numbers up to a limitGraduation exam preparation · The while loopReading numbers from inputwhile loops
- Write a programBasicCounting down to 5Graduation exam preparation · The while loopReading numbers from inputThe if statementwhile loops
- Algorithmic problemElementaryThe Collatz sequenceGraduation exam preparation · The while loopReading numbers from inputInteger division and remainder: // and %Two branches: if – elsewhile loops
- Algorithmic problemElementaryTo binaryGraduation exam preparation · The while loopText: the str typeReading numbers from inputInteger division and remainder: // and %while loops
- Write a programBasicTrain passengersGraduation exam preparation · Mixed tasksReading numbers from inputThe if statementwhile loopsCounting and summing in a loop
- Write a programBasicLeap yearGraduation exam preparation · Mixed tasksReading numbers from inputInteger division and remainder: // and %Logical operators: and, or, notTwo branches: if – else
- Write a programElementaryA bounded Fibonacci sequenceGraduation exam preparation · Exceptions (try – except)Reading numbers from inputwhile loopsList methods: append, pop, remove, …try – except