SyntaxStudy
Sign Up

Hello World Function

JAVASCRIPT Easy +10 XP
Problem Description
Write a function called `greet` that takes a name as a parameter and returns the string "Hello, [name]!".

Example:
greet('Alice') → "Hello, Alice!"
greet('World') → "Hello, World!"

Test Cases

1
Input: greet('Alice')
Expected: Hello, Alice!
2
Input: greet('World')
Expected: Hello, World!
3
Input: greet('Bob')
Expected: Hello, Bob!
Your Solution