class Data:
def __init__(self,dia,mes,ano):
self.dia = int(dia)
self.mes = int(mes)
self.ano = int(ano)
def formatada(self):
print("{:02d}/{:02d}/{:02d}".format(self.dia,self.mes,self.ano))
>>> from datas import Data
>>> d = Data("01","05",2020)
>>> d.formatada()
'01/05/2020
>>> d2 = Data(21,11,2017)
>>> d2.formatada()
21/11/2017