Dupstring

View as PDF

Submit solution


Points: 5 (partial)
Time limit: 1.0s
Memory limit: 32M

Author:
Problem type
Allowed languages
Python

Write a program that copies a string for n times.

Input Specification

2 lines. The first line is the string to be copied. The second line denotes the number of copies.

Output Specification

One line of n copies of the specified string.

Sample Input

ok
5

Sample Output

okokokokok

Hint

string multiply


Comments


  • 0
    114090006  commented on March 8, 2026, 5:09 p.m.

    print()有參數end默認\n,所以輸入print(string,end="")就能使用for迴圈且不會換行


  • 0
    112034059  commented on Sept. 16, 2025, 10:10 a.m. edited

    s


  • 0
    tommy12926  commented on Sept. 27, 2023, 1:41 a.m. edited

    .