Python Basics – Let’s Code the
Fun Way! 🐍✨
Class 11 IP | Presented by Apurwa
Chouhan
Who developed python?
• Guido van Rossum in 1989
• Officially released in 1991.
• amed after the British comedy show “Monty
Python’s Flying Circus”, not the snake!
Why Python?
• • Simple & beginner-friendly
• • Looks like English
• • Used in games, apps, AI, websites
• • When you learn Python, even your
computer smiles 🐍💻
Your First Program
• print("Hello, World!")
• Output: Hello, World!
• ➡ Example of the simplest Python program.
Variables
• Variables are containers that store data
• Example:
• name = "ram"
• age = 5
• ➡ A variable is a name given to a value.
Data Types
• Different kinds of values:
• • int → numbers (10, 20)
• • float → decimal numbers (3.14)
• • str → text ('hello')
• • bool → True/False
• ➡ Guess the data type of 123 and "123"
keywords in python
• Reserved words, have special
meaning.
• Examples: if, else, while, for, True,
False, break, continue
Input from User
• We can take input from the user:
• name = input("Enter your name: ")
• print("Welcome", name)
• ➡ This allows interaction with the program.
Operators
• Operators are used to perform calculations:
• + → Addition
• - → Subtraction
• * → Multiplication
• / → Division
• ➡ Example: 10 - 3 = 7
Conditions (if-else)
• Used to make decisions:
• marks = 75
• if marks >= 33:
• print("You Passed!")
• else:
• print("Better luck next time")
• ➡ Runs code based on condition.
output
• marks = 75
• if marks >= 33:
• print("You Passed! ")
• else:
• print("Better luck next time ")
Loops
• Loops repeat actions:
• for i in range(3):
• print("Hello")
• ➡ Output:
• Hello
• Hello
• Hello
Conclusion
• Summary:
• • Python is simple and powerful
• • First program: print()
• • Variables and Data Types
• • Operators
• • If-Else for decisions
• • Loops for repetition
• ➡ Python makes coding easy and fun! 🐍
Fun Fact 🎉
• Did you know?
• Python is one of the fastest-growing
languages.
• Companies like Google, Netflix,
Instagram, NASA use python.