Advertisement
YavorGrancharov

ConcatenateData

Dec 13th, 2016
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.49 KB | None | 0 0
  1. import java.util.Scanner;
  2. public class ConcatenateData {
  3.     public static void main(String[] args) {
  4.         Scanner console = new Scanner(System.in);
  5.         String firstName = console.nextLine();
  6.         String lastName = console.nextLine();
  7.         int age = Integer.parseInt(console.nextLine());
  8.         String town = console.nextLine();
  9.  
  10.         System.out.println("You are " + firstName + " " + lastName + ", " + "a " + age + "-" + "years old person from " + town + ".");
  11.     }
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement