Translations:Como executar o Prolog/24/en

De Augusto Baffa Wiki
Ir para navegação Ir para pesquisar

1. A Prolog goal is terminated with a period "." In this case the goal was to load a program file. This "bracket" style notation dates back to the first Prolog implementations. Several files can be chain loaded by listing the filenames sequentially within the brackets, separated by commas. In this case, the file's name is 2_1.pl (programs corresponding to Section 7.1 of this tutorial), which contains two prolog programs for calculating the factorial of a positive integer. The actual program in the file is discussed in Section 2.1. The program file was located in the current directory. If it had not been, then the path to it would have to have been specified in the usual way.