Some script is working successful by swi-prolog 5.11.11 on linux-system, but not so well on windows-system by Swi-Prolog 5.6.48
main :-
open(\'output.txt
I'm assuming this was meant to be a failure-driven loop. It doesn't work because the close/1
call, as @hardmath says, is never reached since it is preceded by a fail/1
in the same clause. In effect, the output file is apparently not flushed. This failure-driven loop should be written as:
main :-
open('output.txt', write, OS),
main(OS).
main(OS) :-
elements(Points),
get_set(Eq, Points),
alpha_isotone(Eq, Points),
write(OS,Eq), nl(OS),
false.
main(OS) :- close(OS).