Profitect interview question

How does logistic regression work?