Pregunta de entrevista de Finmatics GmbH

Explain factory pattern. When and why do we need it?