Removed debugging printing
Supports History and right/left arrows. need to check special cases