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

Aquí aparecerá el resultado de la ejecución del código

Tests12
Visible tests
Prueba oculta 7
Prueba oculta 8
Prueba oculta 9
Prueba oculta 10
Prueba oculta 11
Prueba oculta 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