Pergunta de entrevista da empresa Amazon

Explain Factory method and singleton design