+ 1

a,b,c=0,0,0. Write a python program to print all permutations using those three variables. Output: 000, 001, 002,.......999.

Just give me some logic how can i write a program dor this problm.. thanks

26th Nov 2019, 5:22 PM
Abdul Wahab
Abdul Wahab - avatar
5 Respuestas
+ 3
for i in range(0,10): for j in range(0,10): for k in range(0,10): print(i,j,k,",") but, the problem was i was unable to print it in single line
28th Nov 2019, 3:02 AM
rockrun
rockrun - avatar
+ 3
Thankss allot
26th Nov 2019, 5:45 PM
Abdul Wahab
Abdul Wahab - avatar
+ 2
maybe something like this? number_list = [f'{a}{b}{c}' for a in range(10) for b in range(10) for c in range(10)] print(number_list)
26th Nov 2019, 5:38 PM
o.gak
o.gak - avatar
+ 2
rockrun print(i,j,k,end=",")
28th Nov 2019, 3:07 AM
Abdul Wahab
Abdul Wahab - avatar
+ 1
thks a lot bro
28th Nov 2019, 3:11 AM
rockrun
rockrun - avatar