Question: java Write a method delete that takes two strings, str and substr, as parameters. The method will return a string which includes each character in
Write a method delete that takes two strings, str and substr, as parameters. The method will return a string which includes each character in str but has the first occurrence of substr deleted. public static String delete (String str, String substr) Calling delete ("Labyrinthine", "in") will return "Labyrthine" Write a method that takes one string as a parameter and returns a string with each letter duplicated. Letters will appear in the same order as in the parameter. public static String duplicate (String s) Calling duplicate ("Mango") will return the String "Maannggoo" Write a method to change the name format from lastName>,
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
