Skip to content

Commit

Permalink
ADD - nível: avançado, categoria: lambda; exercício: 001
Browse files Browse the repository at this point in the history
  • Loading branch information
rmveiga committed Aug 17, 2020
1 parent dfb239e commit 03f4594
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions avancado/lambda/ex001/main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
nome_completo = str(input('Informe o seu nome completo: '))
primeiro_nome = lambda nome: nome.split()[0]
ultimo_nome = lambda nome: nome.split()[-1]

print(f'Seu primeiro nome é {primeiro_nome(nome_completo)} '
f'e o seu último nome é {ultimo_nome(nome_completo)}')

0 comments on commit 03f4594

Please sign in to comment.