Modo entrevista. Cronômetro de 3 min, sem dicas e sem autocompletar
Welcome by language
FácilMap and Set3 min
Greetings in different languages are already in the Map GREETINGS. The key is the language name, the value is the greeting.
Write a function greet(language) that returns the greeting in that language. If the language is not in the dictionary, return the English 'Welcome'.
Exemplos
greet('dutch')Retorna 'Welkom'
greet('IP_ADDRESS_INVALID')Retorna 'Welcome'
Carregando o editor...
- Entrada
greet('dutch')Esperado'Welkom' - Entrada
greet('english')Esperado'Welcome' - Entrada
greet('IP_ADDRESS_INVALID')Esperado'Welcome'
Os testes ocultos rodam no envio