-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAtividade23.py
More file actions
36 lines (31 loc) · 1.13 KB
/
Atividade23.py
File metadata and controls
36 lines (31 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
while True:
nome = input("Digite seu nome(mais que tres caracteres): ")
if len(nome) <= 3:
print("É necessario mais de tres caracteres, digite novamente")
else:
break
while True:
idade = int(input("Digite sua idade(idade entre 0 e 150): "))
if 0 <= idade <= 150:
break
else:
print("Idade invalida, digite novamente")
while True:
salario = int(input("Digite seu salario: "))
if salario <= 0:
print("Digite um salario maior que zero")
else:
break
while True:
estado_civil = input("Digite seu estado civil -- 's', 'c', 'v' ou 'd': ").lower()
if estado_civil == "s" or estado_civil == "c" or estado_civil == "v" or estado_civil == "d":
break
else:
print("valor invalido, digite novamente!")
while True:
sexo = input("digite sua sexualidade -- 'f'- feminino e 'm'-masculino: ").lower()
if sexo == "f" or sexo == "m":
break
else:
print("valor invalido, digite novamente")
print(f"nome: {nome}\n idade: {idade}\n salario: {salario}\n estado civil: {estado_civil}\n sexo: {sexo}")