Computational Logic. The assignment on computational logic will have two pieces. Be sure you understand the discussion in class about the form the input is supposed to take, and the roles of the basic files. To solve this first part of the problem, you only need to understand mainO.py (the simplest version of the prover). This version can read and store the input clauses in clauses.txt and can prove any proposition. Your task is to add the following.
1. Add predicates "showproof" and "noshowproof" that toggle a variable that tells the theorem prover whether to show the clauses used in a particular proof or not.1.
2. Modify the code so that it collects the clauses used in each proof and prints them before it prints "yes". Hint - you will need to write methods for the Literal class similar to isExitO, and you will have to call them at that same in the main while loop.
This assignment amounts to only a few lines of code. The next assignment will be larger, but will require a deeper understanding of the methodology and theory of computational logic.