Write a Java program , should ask you to enter first name and last name, then you should display the name together and say length of the name
Answers
Answered by
1
Answer:
Explanation:
import java.util.Scanner;
class NameExample {
public static void main(String[]args)
{
String name;
Scanner sc = new Scanner (System.in);
System.out.println("Enter the name");
name = sc.nextLine();
System.out.println(name);
}
}
Answered by
1
Refer the attachment
Hope it will help you
Attachments:
Similar questions