I\'m trying to write to a txt file using prolog so I tried making a simple predicate to test that, here it is:
writefacts():- open(\'output.txt\', write, Out), write(