002-001-006

Scanner Class Basics: Name Survey

Easy

Problem Description

Scanner class Basics: Name Survey

In this problem, you will create a program that uses the Scanner class to read a name from keyboard input and displays a formatted survey result to standard output.

Learning Objective: Use Scanner class to input strings from keyboard

In a name survey program, input and display a name. Scanner class is a tool for receiving data from the keyboard.

Input

Line 1: Name (string)

Output

================================
      Name Survey
================================
Thank you for your input!
Your name: [name]
================================

Examples

Example 1: Taro Tanaka

Input:

Taro Tanaka

Output:

================================
      Name Survey
================================
Thank you for your input!
Your name: Taro Tanaka
================================

Ready to Try Running Code?

Log in to access the code editor and execute your solutions for this problem.

Don't have an account?

Sign Up