Capitalize Every Word

This style is often used for catchy phrases, headings, and short quotes. Write to_jaden_case, which capitalizes the first letter of every word in the string s. Words are separated by single spaces, and the rest of each word should stay unchanged.

Примеры

Ввод
"How can mirrors be real if our eyes aren't real"
Вывод
"How Can Mirrors Be Real If Our Eyes Aren't Real"
Ввод
"most trees are blue"
Вывод
"Most Trees Are Blue"
Ввод
"hello world"
Вывод
"Hello World"

Нужно реализовать

def to_jaden_case(s: str) -> str:

Теги

strings
PostgreSQLv16

Itt jelenik meg a kód futtatásának eredménye

Tests12
Visible tests
Rejtett teszt 7
Rejtett teszt 8
Rejtett teszt 9
Rejtett teszt 10
Rejtett teszt 11
Rejtett teszt 12

They run when you press "Submit" — your whole solution is checked against them so you can't hard-code answers for the visible cases.

Focus radio
Paused · SomaFM · Fluid