Python Programming Project Class12
Python Programming Project Class12
Acknowledgement
I would like to express my special thanks to my teacher for guiding me and providing the opportunity to work
on this project. I also thank my parents and friends for their support.
Certificate
This is to certify that this project titled 'Python Programming' is the bonafide work of _______ of Class 12th,
Introduction to Python
Python is a high-level, interpreted programming language created by Guido van Rossum in 1991. It
Features of Python
- Interpreted Language
- Dynamically Typed
- Portable
- Extensive Libraries
Applications of Python
- Automation
- GUI Development
Python Programming Project
- Machine Learning
Python Syntax
Example:
print("Hello, World!")
Output:
Hello, World!
Example:
name = "Riya"
age = 18
height = 5.6
is_student = True
Operators in Python
- Arithmetic: +, -, *, /
Control Structures
Example:
age = 18
print("Eligible to vote")
else:
print("Not eligible")
Functions in Python
def greet(name):
print(greet("Ankit"))
Output:
Hello Ankit
a = 10
b = 20
sum = a + b
print("Sum:", sum)
Output:
Sum: 30
num = 7
if num % 2 == 0:
print("Even")
else:
print("Odd")
Python Programming Project
Output:
Odd
Program 3: Factorial
n=5
fact = 1
fact *= i
print("Factorial:", fact)
Output:
Factorial: 120
a, b = 0, 1
for _ in range(5):
a, b = b, a + b
Output:
01123
Program 5: Palindrome
s = "madam"
if s == s[::-1]:
print("Palindrome")
else:
Python Programming Project
print("Not Palindrome")
Output:
Palindrome
a = 15
b=5
print("Add:", a + b)
print("Divide:", a / b)
Output:
Add: 20
Divide: 3.0
Conclusion
This project helped me understand the basics of Python programming. I practiced writing code, using logic,
Bibliography
- NCERT Book
- w3schools.com
- geeksforgeeks.org
- python.org