LearnPy Hub
← Functions problems
Easy

repeat(text, times)

Write repeat(text, times) that returns the text repeated with a space between copies. Read a word and a number and print the result.

Input

A word, then an integer ≥ 1.

Output

One line.

Sample 1

Input
hi
3
Output
hi hi hi

Sample 2

Input
Python
1
Output
Python
solution.py
Output appears here
repeat(text, times) · Python practice problem · LearnPy Hub