LET’S LEARN
PYTHON
Lesson 1:
Introduction and Printing
❑Understand the purpose of Python and its uses
in programming.
❑Identify and use basic Python command –
print().
❑Create a simple Python program to print
personal information.
What is
Python?
Python is a popular programming
language used in web development,
data analysis, AI, and more.
Known for its simplicity and
readability.
Used in many well-known
applications, including YouTube,
Instagram, and Google.
It was created by Guido van
Rossum, and released in 1991.
web development (server-
side),
Python
is software development,
used mathematics
for: system scripting.
Why Learn Python?
Useful across Python works on
Easy to learn, even various fields: different platforms
for beginners. technology, science, (Windows, Mac,
gaming, etc. Linux, Raspberry Pi,
etc).
Python has syntax
Python has a simple that allows
syntax similar to developers to write Python skills are in
the English programs with fewer high demand.
language. lines than some
other programming
languages.
Getting Started
•We’ll use a simple online editor to
write and run Python code.
•https://programiz.pro/ide/python
print()
•First task: Write a basic program to print a
message.
•The print() function prints the specified message to
the screen, or other standard output device.
•Code Example: print("Hello, World!")
1) Write a Python program to display your grand
parents’ name.
# Program to Display Grand Parents name
print(“Rita”) # Grand Mother
print(“William”) # Grand Father
Python Comments
• Comments can be used to explain Python code.
• Comments can be used to make the code more readable.
• Multiline comments can be added using triple quotes in the
code.
• Comments starts with a #, and Python will ignore them:
Example 2.
"""
Example 1.
This is a comment
#This is a comment
written in
print("Hello, World!")
more than just one line
"""
print(‘Hello, World!’)
Activity – My Info Program
➢Write a code to print your Name,
Age, Student ID, Transport
details(OT/STS), Email Address,
Phone no. and favorite subject
in separate lines.
➢Use comment to explain the code.
Know more about Python!
Pyhton supports both: single and double quotes (example:
“Python” is same as ‘Python’)
Python is a case sensitive language (example: print is
different than Print)
Comma can be used to print multiple values using same
print function (example: print(“Python”, “Javascript”,
“Java”, “C++”, “C#”, “are some of the most popular
programming languages”)
Identify the Syntax error
# Program to Display
Print(“Grade 7”) # Section
print[‘Ms. Sushma Bavishi’] # Supervisor
Progress Check
Insert the missing part of the code below to output - Welcome to ICT Lab
(“ Welcome to ICT Lab”)
Comments in Python are written with a special character, which one?
This is a comment
Today, we learned
about Python, and
print().
Recap
We created a program
to print our name and
age.
Next time, we’ll
learn about variables
in Python!