Prolog has its roots in first-order logic, a formal logic, and unlike many other programming languages.