๐ Top results in the quiz 'Python - Weekly Quiz Challenge ๐ค'
๐ 5 questions
โฑ 30 seconds per question
๐ค 48 people took the quiz
๐ฅ @Alexpp83 โ 4 (22.9 sec)
๐ฅ @AgnusTR โ 4 (46.7 sec)
๐ฅ Gerard Zikpi โ 4 (52.9 sec)
4. @Aung25200 โ 4 (55.6 sec)
5. @R_sama_2017 โ 4 (55.7 sec)
6. Md Keramot Ullah Safi โ 3 (49.2 sec)
7. @Imranyemon โ 3 (53.5 sec)
8. Nikil Reddy โ 3 (54 sec)
9. @MrkkvnKlgdn โ 3 (55.1 sec)
10. Samer Alesaleh โ 3 (56.9 sec)
@python_programming_42 โจ
#python #programming #quiz
๐ 5 questions
โฑ 30 seconds per question
๐ค 48 people took the quiz
๐ฅ @Alexpp83 โ 4 (22.9 sec)
๐ฅ @AgnusTR โ 4 (46.7 sec)
๐ฅ Gerard Zikpi โ 4 (52.9 sec)
4. @Aung25200 โ 4 (55.6 sec)
5. @R_sama_2017 โ 4 (55.7 sec)
6. Md Keramot Ullah Safi โ 3 (49.2 sec)
7. @Imranyemon โ 3 (53.5 sec)
8. Nikil Reddy โ 3 (54 sec)
9. @MrkkvnKlgdn โ 3 (55.1 sec)
10. Samer Alesaleh โ 3 (56.9 sec)
Top 10 Results of Yesterday's Quiz๐๏ธโจ
@python_programming_42 โจ
#python #programming #quiz
โค6๐2๐ฅฐ1
What will be the output of print("hello".replace("l", "X"))?
Anonymous Quiz
70%
heXXo
7%
hello
19%
heXlo
4%
Error
โค4๐1
Binary_search.py
483 B
Binary Search in Python ๐
Do not forget to React โค๏ธ to this Message for More Content Like this
Thanks For Joining All โค๏ธโค6๐1๐ฅ1
Which loop runs until a condition is False?
Anonymous Quiz
23%
for loop
47%
while loop
17%
do-while loop
13%
loop-until
โค4๐1
Which function returns the square root of a number?
Anonymous Quiz
10%
math.pow()
62%
math.sqrt()
16%
sqrt()
12%
math.root()
โค3๐1
Functions in Python ๐
Don't Forget to give reactionsโค๏ธ
โค3๐2๐ฅ1
medium_article_reader.py
641 B
Medium Article Reader in Python ๐
Do not forget to React โค๏ธ to this Message for More Content Like this
Thanks For Joining All โค๏ธโค2๐1๐ฅ1
โค3๐2
Important Python concepts that every beginner should know
1. Variables & Data Types ๐ง
Variables are like boxes where you store stuff.
Python automatically knows the type of data you're working with!
2. Conditional Statements ๐
Want your program to make decisions?
Use if, elif, and else!
3. Loops ๐
Repeat tasks without writing them 100 times!
For loop โ Loop over a sequence
While loop โ Loop until a condition is false
4. Functions โ๏ธ
Reusable blocks of code. Keeps your program clean and DRY (Don't Repeat Yourself)!
5. Lists, Tuples, Dictionaries, Sets ๐ฆ
List: Ordered, changeable
Tuple: Ordered, unchangeable
Dict: Key-value pairs
Set: Unordered, unique items
6. String Manipulation โ๏ธ
Work with text like a pro!
7. Input from User โจ๏ธ
Make your programs interactive!
8. Error Handling โ ๏ธ
Catch mistakes before they crash your program.
9. File Handling ๐
Read or write files using Python.
10. Object-Oriented Programming (OOP) ๐งฑ
Python lets you model real-world things using classes and objects.
1. Variables & Data Types ๐ง
Variables are like boxes where you store stuff.
Python automatically knows the type of data you're working with!
name = "Alice" # String
age = 25 # Integer
height = 5.6 # Float
is_student = True # Boolean
2. Conditional Statements ๐
Want your program to make decisions?
Use if, elif, and else!
if age > 18:
print("You're an adult!")
else:
print("You're a kid!")
3. Loops ๐
Repeat tasks without writing them 100 times!
For loop โ Loop over a sequence
While loop โ Loop until a condition is false
for i in range(5):
print(i) # 0 to 4
count = 0
while count < 3:
print("Hello")
count += 1
4. Functions โ๏ธ
Reusable blocks of code. Keeps your program clean and DRY (Don't Repeat Yourself)!
def greet(name):
print(f"Hello, {name}!")
greet("Bob")
5. Lists, Tuples, Dictionaries, Sets ๐ฆ
List: Ordered, changeable
Tuple: Ordered, unchangeable
Dict: Key-value pairs
Set: Unordered, unique items
my_list = [1, 2, 3]
my_tuple = (4, 5, 6)
my_dict = {"name": "Alice", "age": 25}
my_set = {1, 2, 3}
6. String Manipulation โ๏ธ
Work with text like a pro!
text = "Python is awesome"
print(text.upper()) # PYTHON IS AWESOME
print(text.replace("awesome", "cool")) # Python is cool
7. Input from User โจ๏ธ
Make your programs interactive!
name = input("Enter your name: ")
print("Hello " + name)8. Error Handling โ ๏ธ
Catch mistakes before they crash your program.
try:
x = 1 / 0
except ZeroDivisionError:
print("You can't divide by zero!")
9. File Handling ๐
Read or write files using Python.
with open("notes.txt", "r") as file:
content = file.read()
print(content)10. Object-Oriented Programming (OOP) ๐งฑ
Python lets you model real-world things using classes and objects.
class Dog:
def init(self, name):
self.name = name
def bark(self):
print(f"{self.name} says woof!")
my_dog = Dog("Buddy")
my_dog.bark()
Don't Forget to give reactionsโค๏ธ
โค3๐ฅ3๐1