← Back to challenges

Name Greeting!

PythonMediumstringslanguage_fundamentalsformatting

Instructions

Create a function that takes a name and returns a greeting in the form of a string.

Examples

hello_name("Gerald") ➞ "Hello Gerald!"

hello_name("Tiffany") ➞ "Hello Tiffany!"

hello_name("Ed") ➞ "Hello Ed!"

Notes

  • The input is always a name (as string).
  • Don't forget the exclamation mark!
  • If you get stuck on a challenge, find help in the Resources tab.
  • If you're really stuck, unlock solutions in the Solutions tab.
python3
Loading editor…
to run
Walks through the solution with reasoning and edge cases.
Next: Two Makes Ten