Skip to content

Commit b04098b

Browse files
committed
Criando e removendo atributo dinâmico (Pessoa)
1 parent 7f6f86e commit b04098b

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

oo/pessoa.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,10 @@ def cumprimentar(self):
1717
print(lucioano.cumprimentar())
1818
print(lucioano.nome)
1919
for filho in lucioano.filhos:
20-
print(f'Filho: {filho.nome}')
20+
print(f'Filho: {filho.nome}')
21+
22+
lucioano.sobrenome = 'Ramalho'
23+
del lucioano.filhos
24+
print(lucioano.__dict__)
25+
print(joaquim.__dict__)
26+

0 commit comments

Comments
 (0)