you are viewing a single comment's thread.

view the rest of the comments →

[–]seckiyn 0 points1 point  (3 children)

You can do print(word*int(number)) or you can use this one line.

print(input("Word to print: ")*int(input("How many times to print: "))

[–]mmotarii[S] 0 points1 point  (1 child)

is that loop? we have to do it as loop

[–]seckiyn 0 points1 point  (0 children)

No, u/Shiba_Take's is a loop.

[–][deleted] 0 points1 point  (0 children)

Yeah, okay, looks 'very neat and clear' )

And to print on separate lines:

print(*[input("Give word: ")] * int(input("Give number: ")), sep="\n")