Question: java 1 Write a static method that is passed in 2 Strings and return another String made up of the alternating characters from each argument.
java 1

Write a static method that is passed in 2 Strings and return another String made up of the alternating characters from each argument. If one argument is longer than the other, then its characters are tacked on to the end of the return String. Here are some sample calls and their return values: method("abc", "123") returns "a1b2c3" method("xy", "$%&") returns "x$y%&" Notice the leftover characters method("abcd" , "12") returns "a1b2cd" Hint! In this code you may use only one for loop and if statement. No nested loops
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
