A compiler written in Python to translate KLEIN programs into TM assembly language. A group project for the Translation of Programming Languages class at University of Northern Iowa.
Weird. print("kfklo.kln".strip(".kln")) outputs fklo. Perhaps .strip() isn't the best method to use here. We could simply negate the last four characters and make use of python's string indexing operations.
Looks like if the file ends with an 'n' before the extension, the n gets omitted when the strip method is called.
ex: print("on.kln".strip(".kln")) outputs 'o'
Might be an easy fix might be something stupidly difficult to fix.