Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Class notes

Class notes python loop

Rating
-
Sold
-
Pages
5
Uploaded on
18-05-2026
Written in
2025/2026

his document explains Python loops in simple language for beginners. It covers for loops, while loops, syntax, examples, break and continue statements, and practice questions.

Institution
Course

Content preview

Python Loops Notes for Beginners
What is a Loop?
Loop ka matlab hota hai kisi kaam ko baar baar repeat karna.

Python me loops use hote hain:

●​ Repeated tasks ke liye
●​ Time bachane ke liye
●​ Same code ko multiple times chalane ke liye




Types of Loops in Python
1.​ for loop
2.​ while loop




For Loop
For loop kisi sequence ko repeat karta hai.


Syntax
for variable in sequence:
print(variable)




Example 1
for i in range(5):
print(i)

Output:

, 0
1
2
3
4




Example 2
for i in range(1, 6):
print(i)

Output:

1
2
3
4
5




While Loop
While loop tab tak chalta hai jab tak condition true ho.


Syntax
while condition:
print("Hello")




Example
x=1

while x <= 5:
print(x)
x=x+1

Output:

Written for

Course

Document information

Uploaded on
May 18, 2026
Number of pages
5
Written in
2025/2026
Type
Class notes
Professor(s)
Saumya singh
Contains
All classes

Subjects

$3.99
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Get to know the seller
Seller avatar
sabihaanwaar

Get to know the seller

Seller avatar
sabihaanwaar
Follow You need to be logged in order to follow users or courses
Sold
-
Member since
1 day
Number of followers
0
Documents
2
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions