Read a name and greet it.
What to build
A program that reads one line of text and places it inside a sentence.
Requirements
- Read the name with
input(). - Print the whole sentence on one line, with the name in the right place.
Input
One line: a name.
Output
One line: Hello, NAME! Welcome to StepVioz. with the name in place of NAME.
Constraints
The name is one line of text.
Example
Input:
Rahim
Output:
Hello, Rahim! Welcome to StepVioz.
Why it works
input() gives back exactly what was typed. An f-string or joined text then puts that name inside the fixed words of the sentence.
Examples
Example 1 · Input
Rahim
Expected output
Hello, Rahim! Welcome to StepVioz.
Example 2 · Input
Nadia
Expected output
Hello, Nadia! Welcome to StepVioz.
Prompts inside input() are ignored when checking, so input("n: ") is fine.
Hints
Hint 1
An f-string such as f"Hello, {name}!" puts the name inside the text.
Solution
Show one correct solution (try it yourself first)
name = input()
print(f"Hello, {name}! Welcome to StepVioz.")