public class StringHelper { public static String multiply(String s) { String result = ""; for (int i = 1; i <= 5; i++) { result = result.concat(s); } System.out.println(result); return result; } public static String multiply(String s, int count) { String result = ""; for (int i = 1; i <= count; i++) { result = result.concat(s); } System.out.println(result); return result; } public static void main(String[] args) { StringHelper text = new StringHelper(); text.multiply("Sharry"); text.multiply("Amigo", 3); } }