Skip to main content
Mentr by PaprlybyPaprly

Learn Python free.Start with one line of code.

A free Python course for beginners: 10 short lessons, 500+ practice questions and a free Python compiler in your browser. Go from your first line of code to a quiz game you build yourself. No 60-hour videos, no experience needed.

See the 10 lessons
Price
₹0, no card
Level
Total beginner
Lessons
10, self-paced
Practice
500+ questions
BEGINNER
INTERMEDIATE
ADVANCED
python quiz.py
PYTHON QUIZ Question 1: What does print() do?> display textCorrect! Question 2: Which symbol compares two values?> ==Correct! Your score: 8/10Excellent work!$ 

↑ The quiz game you build in Lesson 10.

In short

Mentr Learn Python is a free online Python course for beginners. Python Beginner has 10 lessons: printing text, variables, user input, if/else, logic, loops, strings, lists and functions, then a final project where you build a quiz game. It includes 500+ practice questions, lesson notes and a free online Python compiler. It costs ₹0, needs no card, and works for school students from Class 6 as well as adults starting from zero.

01 / A new way

You don’t need another 60-hour Python course.

Most beginners buy a long video course, watch a few hours and quietly stop. Nobody learns to code by watching. You learn by writing code, getting it wrong and fixing it.

So that’s the whole course: short lessons where you do something every minute, questions that check you instantly, and a compiler right in your browser. No paid program, no 400-page documentation, nothing to install.

The usual way

Mentr Learn Python

A 60-hour video course you half-watch at 2× speed

About 8 hours of short lessons where you do something every minute

₹3,000 to ₹50,000 for a paid program or class

₹0. No trial, no card, nothing locked

Long documentation written for working engineers

Plain English and school-level examples, one idea at a time

Install Python and set up an editor before line one

Code runs in your browser, even on a phone

Nobody checks your work until the exam

Every answer is checked instantly, with a hint when you're wrong

A researched path, not a playlist

01

Predict, then run

You guess what code will do before you see it. Wrong guesses are where the learning happens.

02

Worked examples first

You watch a program get built line by line, then build one yourself. Beginners learn faster this way than from a blank page.

03

Quick checks, often

A question after every idea, not one big test at the end. Recalling something is what makes it stick.

04

Small wins, every day

XP for every right answer, badges and a daily streak keep you coming back for ten minutes a day.

02 / What you get

Everything you need to learn Python. All free.

500+ practice questions, a free Python compiler, lesson notes and runnable examples — in one place, built for beginners, and working on any laptop or phone.

500+

Practice questions

Multiple choice, predict the output, fix the bug, fill the blank, put lines in order and write your own code. All checked instantly.

Free

Python compiler

Write and run any Python program in your browser. Type input() answers right in the console, like a real terminal. Nothing to install.

10

Lessons with notes

Short slide notes for every lesson, with diagrams, tables, exam tips and flashcards. Read them again any time before a test.

Live

Runnable examples

Step through code line by line and see each variable change. Then edit the example and run it yourself.

1

Final project

Build a complete quiz game on your own, with hints one at a time if you get stuck.

50

Levels, badges, streak

Earn XP for every right answer, climb 50 levels, unlock 10 badges and keep a daily streak.

Free Python compiler

Write any program. Press Run. It works, even on your phone.

Real Python 3, running in your browser. When your program asks a question with input(), you type the answer right in the output, like a real terminal. Errors point to the exact line and explain the fix in plain English.

mentr python compiler
▶ Run main.py What is your name? AaravHow old are you? 12Hi Aarav! Next year you will be 13. finished in 4 ms$ 

03 / Compare

How is this different from other ways to learn Python?

It’s not a video loop, and it’s not a paid program. Here’s how Mentr Learn Python compares with the usual options, row by row.

Mentr Learn Python compared with other ways to learn Python
FeatureFree · this courseMentr Learn PythonYouTube video coursesPaid video coursesCoding classesDocs & tutorial sites
Price₹0, everything includedFree, with adsPaid course feeHigh fee, often monthlyFree
Time to learn the basicsAbout 8 hours, hands-on10–60 hours of video20–60+ hours of videoMonths of fixed classesNo clear path
How you learnYou do: predict, fix and write codeYou watchYou watch and copyGroup pace, set by the classYou read long pages
Practice with instant feedback500+ questions, checked instantlyNoneA few quizzesHomework, checked laterRarely
Write and run codeBuilt-in compiler, nothing to installInstall Python yourselfUsually install yourselfOn the class computerSome have a try-it box
Works on a phoneYes, including the compilerWatch onlyWatch onlyNoReading only
When you're stuckHints, error line highlighted, plain-English fixScroll the commentsPost in a Q&A forumWait for the next classSearch on your own
Made for school studentsYes, Class 6+ and CBSE-friendlyMixedMostly for adultsDepends on the classWritten for developers
Progress you can seeXP, 50 levels, badges, streakNoneProgress bar, certificateTeacher feedbackNone

← Swipe to see all columns

Compares typical formats, not specific brands. Prices and course lengths vary.

Skip the 60 hours of video. Start writing Python today.

04 / The basics

What is Python?

Python is a programming language — a way to give a computer instructions it can follow. It’s known for being easy to read, which is why it’s the most popular first language for beginners.

You write a line like print("Hello"), run it, and the computer shows Hello. Every app, game and website is made of instructions like this — just many more of them.

What can you make with Python?

Games and quizzes

Score counters, guessing games, quiz apps — the kind of thing you build in this course.

Websites and apps

Parts of apps you use every day, like YouTube and Instagram, run on Python.

Data and AI

Most AI and machine learning tools are built with Python. So is a lot of science research.

05 / Why Python

Why learn Python first?

Because it’s the easiest real programming language to start with. Python code is short and reads almost like English. Here’s the same program — show the word Hello — in Java and in Python.

Java · 5 lines

Main.java
1public class Main {2    public static void main(String[] args) {3        System.out.println("Hello");4    }5}

Five lines, and a lot of extra words, before anything shows on screen.

Python · 1 line

main.py
1print("Hello")

One line. You can read it out loud and know exactly what it does.

01

It’s easy to read

if score >= 50: print("Passed") reads almost like English. You spend your time thinking about the problem, not fighting with symbols.

02

It’s taught in school

CBSE Computer Science and Informatics Practices in Class 11 and 12 use Python. Learning it now gives you a head start.

03

It’s used for real work

Websites, apps, games, data analysis and AI tools are all built with Python. It’s not a toy language.

04

It makes other languages easier

Loops, lists and functions work the same way in Java, C++ and JavaScript. Learn them once in Python and the next language is much easier.

06 / Inside a lesson

How does each lesson work?

Every lesson follows the same five steps, so you always know what comes next. And every lesson ends with you writing a small program on your own — not just answering a quiz.

  1. Step 1

    Learn

    A new idea, explained with an everyday example.

  2. Step 2

    Understand

    Read a short piece of code and guess what it will do.

  3. Step 3

    Guided example

    Build a small program step by step, with help.

  4. Step 4

    Practice

    Quick questions with instant feedback: predict, fix and write code.

  5. Step 5

    Mini challenge

    Write a small program on your own to finish the lesson.

07 / Syllabus

What will you learn in Python Beginner?

10 lessons, from your first line of code to your first full project. Tap a lesson to see what’s inside: the topics, the code you’ll write, a practice question to try, the mistake to avoid and a small challenge.

01Welcome to PythonGiving instructions to a computer

A robot does nothing until it gets exact instructions, in the right order. Python is a way to write those instructions.

Concepts

  • What programming is
  • What Python is and where it’s used
  • How a computer follows instructions
  • print() and text (strings)
  • Comments with #
  • Order of execution

Practice set

  1. 1.Predict the output
  2. 2.Choose the correct print()
  3. 3.Find the missing line
  4. 4.Rearrange instructions
  5. 5.Multiple choice
  6. 6.Write your own introduction

Watch out

Text needs quotes. print(Hello) is an error; print("Hello") works.

By the end

Write and run a multi-line program and explain the order it runs in.

Guided build · My Introduction

lesson_01.py
1# This is my first program2print("My name is Aarav")3print("I am 12 years old")4print("I love games")

Predict before you run

print("A")
print("B")
print("C")

Which letter appears first?

Show answer

A. Python runs a program from the top line down, one line at a time.

Mini challenge

Introduce yourself in at least four lines.

02VariablesGiving information a name

A variable is a labelled box. In score = 100, score is the label on the box and 100 is what’s inside.

Concepts

  • Creating a variable
  • Naming rules
  • Changing a value
  • str, int, float, bool
  • Checking with type()

Practice set

  1. 1.Spot the variable and the value
  2. 2.Name the data type
  3. 3.Predict output
  4. 4.Fix invalid variable names
  5. 5.Change variable values
  6. 6.Multiple choice

Watch out

Names can’t start with a number or contain spaces. player_score works; 2score and player score don’t.

By the end

Store text, whole numbers, decimals and True/False, and tell the four types apart.

Guided build · Player Profile

lesson_02.py
1name = "Aarav"2age = 123height = 5.44is_student = True56print(name, age, height, is_student)

Predict before you run

score = 10
score = 20
print(score)

What gets printed?

Show answer

20. A variable holds only its latest value; the 10 is replaced.

Mini challenge

A game player profile with name, age, score and favourite game.

03Input & CalculationsMaking programs interactive

Until now the program knew everything in advance. With input(), the person at the keyboard gets to answer.

Concepts

  • input() and prompts
  • Why input arrives as text
  • Converting with int() and float()
  • + - * /
  • % for remainders

Practice set

  1. 1.Predict calculations
  2. 2.Choose the correct operator
  3. 3.Convert input correctly
  4. 4.Fix broken programs
  5. 5.Complete calculator code
  6. 6.Multiple choice

Watch out

% gives the remainder, not a percentage. number % 2 == 0 means the number is even.

By the end

Ask for values, convert them, and calculate with all five operators.

Guided build · Simple Calculator

lesson_03.py
1num1 = int(input("First number: "))2num2 = int(input("Second number: "))34print(num1 + num2)5print(num1 - num2)6print(num1 * num2)

Predict before you run

age = input("Age: ")
print(age + 1)

Why does this crash?

Show answer

input() always returns text, and text can’t be added to a number. int(input("Age: ")) fixes it.

Mini challenge

A bill calculator: enter price and quantity, print the total.

04Making Decisions with ifPrograms that choose

If it’s raining, take an umbrella. Otherwise, don’t. Programs make decisions the same way, one condition at a time.

Concepts

  • Why programs need decisions
  • if and else
  • elif for more than two paths
  • == != > < >= <=
  • Indentation marks the block

Practice set

  1. 1.Which branch runs?
  2. 2.Complete the condition
  3. 3.Find the wrong operator
  4. 4.Predict output
  5. 5.Multiple choice
  6. 6.Turn a real rule into an if

Watch out

= stores a value; == compares two values. Mixing them up is the most common bug in this lesson.

By the end

Write if / elif / else using all six comparison operators.

Guided build · Game Entry Checker

lesson_04.py
1age = int(input("Enter your age: "))23if age >= 10:4    print("You can play!")5else:6    print("You cannot play yet.")

Predict before you run

score = 72

if score >= 90:
    print("Excellent")
elif score >= 70:
    print("Good")
else:
    print("Try again")

Which word is printed?

Show answer

Good. Python checks from the top and stops at the first condition that is true.

Mini challenge

A grade checker: marks in, grade out.

05Thinking with LogicCombining conditions

You can enter the competition if you’re at least 10 and you scored at least 50. Both have to be true. This lesson is less new syntax, more thinking.

Concepts

  • and, or, not
  • True and False as values
  • Combining comparisons
  • Nested if, used sparingly

Practice set

  1. 1.True or false challenges
  2. 2.Choose and vs or
  3. 3.Predict output
  4. 4.Complete conditions
  5. 5.Convert rules into code
  6. 6.Debug logic errors

Watch out

Nesting works, but two levels is usually the limit. A single and often reads more clearly.

By the end

Combine conditions with and, or and not, and decide when nesting helps.

Guided build · Competition Eligibility

lesson_05.py
1age = int(input("Age: "))2score = int(input("Score: "))34if age >= 10 and score >= 50:5    print("Eligible")6else:7    print("Not eligible")

Predict before you run

A = True
B = False

print(A and B)
print(A or B)
print(not A)

What are the three results?

Show answer

False, True, False. and needs both; or needs one; not flips the value.

Mini challenge

A game unlock: enough points and the right level opens the next stage.

06LoopsMaking computers repeat work

Typing print("Hello") five times is fine. Then someone asks for five hundred.

Concepts

  • Why loops exist
  • for and range()
  • range(5) vs range(1, 6)
  • The loop variable
  • while loops
  • Avoiding infinite loops

Practice set

  1. 1.Predict loop output
  2. 2.Count backwards
  3. 3.Fill in missing loop code
  4. 4.Make number patterns
  5. 5.Find the infinite loop
  6. 6.Multiple choice

Watch out

A while loop needs something inside it to change, or it never stops.

By the end

Repeat work with for and range(), and write a while loop that ends.

Guided build · Multiplication Table

lesson_06.py
1number = int(input("Enter a number: "))23for i in range(1, 11):4    print(number, "x", i, "=", number * i)

Predict before you run

for i in range(1, 4):
    print(i)

What gets printed?

Show answer

1, 2, 3. range stops just before the end number.

Mini challenge

A countdown: 5, 4, 3, 2, 1, GO!

07StringsWorking with text

To Python, the word "Python" is six characters standing in a row, numbered from 0.

Concepts

  • Indexing from 0
  • len()
  • .upper() and .lower()
  • .strip()
  • .replace()
  • Joining text

Practice set

  1. 1.Predict string output
  2. 2.Find the character at a position
  3. 3.Work out the length
  4. 4.Fix string operations
  5. 5.Transform text
  6. 6.Multiple choice

Watch out

Index and length are different. The last letter of a 6-letter word is at index 5, not 6.

By the end

Read, measure and change text with indexing and string methods.

Guided build · Username Generator

lesson_07.py
1first = input("First name: ")2last = input("Last name: ")3number = input("Favourite number: ")45username = first.lower() + last[0].lower() + number6print(username)

Predict before you run

name = "Python"
print(name[0])
print(len(name))

What two values are printed?

Show answer

P and 6. Counting starts at 0, but len() counts every character.

Mini challenge

A secret message transformer that changes a message in several steps.

08ListsWorking with many values

fruit1, fruit2 and fruit3 work for three fruits. A list keeps all of them under one name, in order.

Concepts

  • Why lists exist
  • Creating a list
  • Indexing and changing items
  • append() and remove()
  • len() on a list
  • Looping through a list

Practice set

  1. 1.Identify indexes
  2. 2.Predict output
  3. 3.Add and remove items
  4. 4.Fix list errors
  5. 5.Loop through a list
  6. 6.Put operations in order

Watch out

On a 3-item list, games[3] is an error. The last item is games[2].

By the end

Create a list, change it, and loop through every item.

Guided build · Favourite Games

lesson_08.py
1games = ["Minecraft", "Chess", "Roblox"]2games.append("Football")3games.remove("Chess")45for game in games:6    print(game)

Predict before you run

games = ["Minecraft", "Chess"]
games.append("Roblox")
print(len(games))

What gets printed?

Show answer

3. append() adds one item to the end.

Mini challenge

A shopping list program: start with items, add one, remove one, print all.

09FunctionsCreating your own commands

Writing the same lines again and again? Give them a name, then call the name.

Concepts

  • Why functions exist
  • def and calling
  • Parameters and arguments
  • return
  • Reusing code

Practice set

  1. 1.Label the parts of a function
  2. 2.Call functions
  3. 3.Fill in parameters
  4. 4.Predict returned values
  5. 5.Fix broken functions
  6. 6.Write small functions

Watch out

print() shows a value on screen. return hands it back so the rest of the program can use it.

By the end

Write functions with parameters and return values, and reuse them.

Guided build · Score Calculator

lesson_09.py
1def calculate_score(correct, total):2    return correct * 100 / total34result = calculate_score(8, 10)5print(result)

Predict before you run

def add(a, b):
    return a + b

print(add(5, 3))

What gets printed?

Show answer

8. 5 and 3 go in, add() returns their sum.

Mini challenge

Write greet(), calculate_total() and check_score(), then use all three in one program.

10Final ChallengeBuild a mini quiz game

No video this time. A problem, a blank file, and five hints if you need them.

Concepts

  • Variables and input
  • Strings and conditions
  • Loops and lists
  • Functions
  • Planning before coding

The program must

  1. 1.Welcome the player
  2. 2.Ask several questions
  3. 3.Accept answers
  4. 4.Check whether each answer is correct
  5. 5.Keep a score
  6. 6.Show the final score
  7. 7.Give a result based on the score

Watch out

Get one question working first, then add the loop.

By the end

Plan and build a complete program from a blank file.

Starter structure · Mini Quiz Game

lesson_10.py
1questions = ["What does print() do?", "Comparison symbol?"]2answers = ["display text", "=="]3score = 045for i in range(len(questions)):6    reply = input(questions[i] + " ")7    if reply == answers[i]:8        score = score + 1

Your task

Finish the game with your own questions and a final result message.

All 10 lessons are free. Start with Lesson 1 today.

08 / Final project

What do you build at the end?

A quiz game, written by you. Lesson 10 has no video. You get a task: build a game that asks questions, checks the answers and keeps score. You won’t see the full answer. If you get stuck, open a hint.

Stuck? Hints, one at a time

  1. 1Where will you store the player’s score?
  2. 2How can you repeat the questions?
  3. 3How do you check whether an answer is correct?
  4. 4Could a list hold your questions?
  5. 5Could a function keep the code organised?

Then a final check-up

  • AUnderstand10 multiple-choice questions
  • BPredict5 “what does this print?” questions
  • CDebug5 broken programs to fix
  • DThink5 plain-English steps to turn into Python
  • ECodePrint 1 to 10 · Find the largest of three · Number guessing game
python quiz.py
PYTHON QUIZ Question 1: What does print() do?> display textCorrect! Question 2: Which symbol compares two values?> ==Correct! Your score: 8/10Excellent work!$ 

The game uses everything from the course: variables, input, text, if/else, loops, lists and functions. When it runs, you’ve written a complete program on your own — and you earn the Python Beginner badge.

09 / Levels

What comes after Python Beginner?

Python Intermediate, then Python Advanced. Finish a level to earn its badge. Beginner is open now; the next two levels are coming soon and will open on this page.

BEGINNER
Live

Level 1

Python Beginner

From your first print() to a working quiz game. No coding background needed.

  • print, variables and data types
  • input and calculations
  • if / elif / else and logic
  • for and while loops
  • strings, lists and functions

Badge earned by: build a complete mini quiz game on your own

INTERMEDIATE
Coming soon

Level 2

Python Intermediate

Write longer programs that hold real data, recover from errors and stay organised.

  • dictionaries, tuples and sets
  • reading and writing files
  • handling errors with try / except
  • modules and the standard library
  • classes and objects, first steps

Badge earned by: build small tools that save and load data

Coming soon

ADVANCED
Coming soon

Level 3

Python Advanced

Think in algorithms, work with outside data and structure code like a developer.

  • searching, sorting and complexity
  • recursion
  • working with APIs and JSON
  • data with lists, dicts and libraries
  • testing and structuring projects

Badge earned by: ship a multi-file project you can show

Coming soon

10 / For parents

Is this Python course right for my child?

Yes, if your child is in Class 6 or above and curious about how apps and games work. No coding experience is needed.

  • It helps at school. Python is the language used in CBSE Computer Science in Class 11 and 12, and in most college coding courses. Starting early makes those classes easier.
  • It’s really free. No trial, nothing locked, no card. Mentr earns from optional tutor connections — not from course fees or your child’s data.
  • You can see the progress. Every lesson ends with a program your child wrote. Ask them to run it for you.
  • Younger child? For Class 3–5, start with Mentr Learn — free coding, AI and maths with no typing.

11 / FAQ

Learn Python free: questions people ask

Can I learn Python for free?

Yes. Python Beginner on Mentr Learn is a full 10-lesson Python course that costs ₹0. There’s no trial, no card and nothing locked behind a payment.

Is Python good for beginners?

Yes. Python is the most popular first programming language because the code is short and easy to read. A first program is one line: print("Hello").

Is Python hard to learn?

The basics are not hard. Python Beginner teaches one idea per lesson, starts with everyday examples, and gives you practice after every new concept. If you can follow a recipe, you can follow a Python program.

What age should a child start learning Python?

Class 6 (around age 11) is a good time to start typed Python. For younger children in Class 3–5, Mentr Learn offers free coding, AI and maths lessons that don’t need typing.

How long does it take to learn Python basics?

Python Beginner is 10 lessons and fully self-paced. At one or two lessons a week, you’d finish the basics in about one to two months, including the final project.

Do I need a long 60-hour Python course?

No. To learn the basics you need practice, not hours of video. Python Beginner is about 8 hours of short lessons where you predict, fix and write code yourself, with 500+ questions that are checked instantly.

Is there a free online Python compiler?

Yes. Every learner gets a free Python compiler that runs in the browser, on laptops and phones. Write any program, press Run, and type answers to input() right in the output console. Nothing to install.

Do I need any coding experience?

No. Lesson 1 starts from zero: what programming is and how to show text on screen with print(). Each lesson builds on the one before.

What will I be able to do after Python Beginner?

Write small programs on your own — a calculator, a grade checker, a times table, a shopping list — and a complete quiz game that uses variables, input, if/else, loops, lists and functions together.

What is Python used for?

Websites and apps, games, automating boring tasks, data analysis, science research, and artificial intelligence and machine learning. Many of the AI tools people use today are built with Python.

When will Python Intermediate and Advanced open?

Python Beginner is open now. Python Intermediate and Python Advanced are being built and will open on this page. Finishing Beginner is the right way to prepare for both.

How is this different from Mentr Learn for Class 3–5?

Mentr Learn for Class 3–5 teaches computer science, AI and maths with narrated videos and block coding — no typing. Learn Python is real typed Python from the first lesson, for older students and beginners of any age.

Can I get a Python tutor too?

Yes. Search Python tutors on Mentr and book a free online demo from any tutor’s profile. The course stays free whether or not you hire a tutor.

Lesson 01

Ready to write your first line of Python?

It takes about a minute. The whole course is free, from Lesson 1 to the final project.

BEGINNER