Melhor maneira de acessar a chave aninhada em Python

def safeget(dct, *keys):
    for key in keys:
        try:
            dct = dct[key]
        except KeyError:
            return None
    return dct
TalaatMagdy