Pergunta de entrevista da empresa Akeyless Security

Given a tree of path segments forming a secret, write a function that lists all possible secrets.