/* INPUT AND OUTPUT: Reading and writing characters (= one letter terms): get_char(X) put_char(X) Reading and writing strings (= any term): read(X) write(X) If X is uninstantiated, next char or string (string ended by . and newline) will be read and X will be instantiated. If X is already instantiated, the goal will be satisfied iff X matches what is read. These goals will only succed once. The predicate nl flushes output, adding a newline. File access: open(X,Y,Z) [X filename, Y is read or write, Z is "filehandle"] close(Z) set_input(Z) set_output(Z) current_input(Z) current_output(Z) Reading and writing acts on "current stream", initially keyboard and screen. This can be changed using filehandles, obtained by open. The change is done by set_input and set_outpot. The current_input and current_output predicates get filehandles for current streams. */