Summary
The greeting function now properly handles empty and whitespace-only names:
- Empty strings (e.g.,
"") now greet "world" instead of printingHello, ! - Whitespace-only strings (e.g.,
" ") are treated as no name and greet "world" - Valid names have surrounding whitespace trimmed (e.g.,
" Ada "greets as "Ada")
Added three tests to verify this behavior. All tests pass with cargo test.