Modify the program of Project 6 so that it checks the infix string for syntax errors as it converts to postfix. The error-detection and recovery strategy should be similar to the one used in the case study. Add a method named conversionStatus to the IFToPFConverter class. When the converter detects a syntax error, it should raise an exception, which the main function catches in a try-except statement. The main function can then call conversionStatus to obtain the information to print when an error occurs. This information should include the portion of the expression scanned until the error is detected. The error messages should also be as specific as possible.
#Sales Offer!| Get upto 25% Off: