We usually program logic using business rules. However, there are cases where business rules are not clear cut and need continuous iterations to get right. This can be costly and difficult. In these cases, the machine learning approach might help.
Article: https://www.linkedin.com/pulse/data-science-machine-learning-vs-rules-based-karthik-guruswamy/