Pattern Program in Python * for loop in python * Pyramid Pattern in Python #shorts #python

preview_player
Показать описание
for loop in python
Print the following Pyramid Pattern in Python:
star pattern program:

*
***
*****
*******
*********

new video for python programming
python code for problem solving approach.
- python for beginners
- learn python in simple way.
- first clear basic concepts.
- solve more problems and consistent practice.

for loop in Python Program
python programming for beginners
python programming examples
python for loop
learn python

#shorts #ytshorts #pythonprogram #tutorial #education #learning #python programmer #python

Рекомендации по теме
Комментарии
Автор

Def triangle(n):
For i in range(1, n+1):
Print(" "*(n-1)+" *"*(i))
triangle(5)

ROCKY-nlwn
Автор

# range for spaces (1, 5), (1, 4), (1, 3)
# range for star (1, 2), (1, 4), (1, 6)
for elee in range(1, 5):
    for spacee in range(1, 6-1*elee):
        print(" ", end="")
    for starr in range(1, 0 + 2*elee):
        print("*", end="")
    print()

littlejin-nx
Автор

Sir bolkar smjha denge to jada axe se smjh aayega please

arti
Автор

n = int(input("Enter your value:\n"))
for i in range(n+1):

for j in range(1, n+1-i):
print(" ", end='')
for k in range(2, i+2):
print(" *", end='')
print()
Try this

shivamrawat
Автор

Numbers=int(input("Enter the value"))
For i in range(0, Numbers+1) :
For j in range(1, i+1) :
print("*" end=" ")
print()


This is run time values input

v.tamilarasan
Автор

Bro why so many lines execute this

while True:
a=int(input(": "))
for i in range(0, a+1):
print(a*i)

gauravjain
Автор

Its perfectly working trust me,
Apko bas jo end=' ' ye jaha likha hai vaha apko bas dono qvama(' ') ke bich ek bar space dena hai and its absolute work perfectly thoda sa apna bhi dimag lagaya karo gyus ye coding hai....
And also try my same project but different code jo maine khud likha hai apne style me --sym=(input(' * \n *** \n \n |'))

tntgamer
Автор

i = 5
for i in range():
print(i) #ye kar diya hota ise acha

harharMahadev
Автор

N = 5
For I in range(1, n+1) :
Left_space = " " * (n - i)
Stars = "* " * (i+i-1)
Print (left_space + Stars)

Ganesha_
Автор

That's the easiest patter
Here are some difficult one
1. ****
* *
* *
****

2. *
***

***
*

3. *
* *
* *
* *
*

4. *
* *
* *

Giga_Thanos
Автор

for i in range(0, 6):
add=(" "*(6-i)+" *"*(i+1))
print(add)

follow this just in 2 lines

katkamvamshi