0

# how to print in python

how to print this using nested loops? 👇 * ** *** **** ***** **** *** ** *

9th May 2021, 5:15 PM
Hosein
11 odpowiedzi
+ 5
This is solved using nested loops. Try to think for the logic before solving the question. https://code.sololearn.com/cvBhhg516Ihy/?ref=app
11th May 2021, 3:24 AM
MrMysterious5
+ 5
Wow, Jan Markus. Nice one-liner used 🤩🤩
11th May 2021, 3:25 AM
MrMysterious5
+ 4
Jan Markus nice... But his teacher will smell the Braten and then...😤😤😤 Trotzdem....wirklich hübsch.
9th May 2021, 7:55 PM
Oma Falk
+ 4
Finally....one loop for each row and the nested one for the cols like Adam Riese would have told us if he was born a bit later. Concerning the ranges ....Jan Markus did the work for u.
9th May 2021, 7:58 PM
Oma Falk
+ 3
9th May 2021, 5:49 PM
Aniket kumar
+ 3
Try it like this: n = 5 for i in range (1, n + 1): for j in range (1, i + 1): print ('*', end = '') print() for i in range (n, 0, -1): for j in range (1, i + 1): print ('*', end = '') print()
11th May 2021, 8:13 AM
Сергей Маслов
+ 2
Jan Markus which font did you used to write code??
11th May 2021, 11:24 AM
AKSHAY🇮🇳
+ 2
for i in range(1): for j in range(1): print("*\n**\n***\n****\n*****\n****\n***\n**\n*")
18th Jun 2021, 7:21 AM
#0009e7 [get]
+ 1
Jan Markus zeig mal den oneliner...
9th May 2021, 7:41 PM
Oma Falk
+ 1
print(2*2) = 4 program finishes. Symbol (*) mean multiplication try it and hope this helps you! Check my projects for more info!
18th Mar 2022, 5:43 PM
Hrithika
0
hi for 𝚒 in 𝚛𝚊𝚗𝚐𝚎(-4,5): if i<0: print((5-(-1*𝚒))*'*') else: print((5-(𝚒))*'*')
11th May 2021, 4:58 PM