Question: ALLENGE TIVITY 4 . 2 . 1 : Write a method that changes a name so that the last name 5 6 4 . 3

ALLENGE
TIVITY
4.2.1: Write a method that changes a name so that the last name
564.3811828.93zay7
Write a method lastNameFirst that takes a string containing a name suc that returns the string with the last name first, such as "Smith, Harry" 0
8 Qparam name a name such as "Mary Jane Lee"
9 Greturn the reversed name, such as "Lee, Mary Jane".
10
Your code goes here **
15
16
}
17
public static void main(string[] args)
19
{
20
Scanner in = new Scanner (
System.in);
21
String name = in. nextLine();
22
System.out.println(lastNameFirst(name));
23
}
24
 ALLENGE TIVITY 4.2.1: Write a method that changes a name so

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!