4 lines
113 B
Java
4 lines
113 B
Java
|
|
public static String repeat(String str, int times) {
|
||
|
|
return new String(new char[times]).replace("\0", str);
|
||
|
|
}
|