Subject

    Computer Science

    Topic

    Artificial Intelligence

    What is the purpose of the cut (!) operator in PROLOG?

    a)
    To concatenate lists
    b)
    To define recursion
    c)
    To control backtracking
    d)
    To end a program

    Explanation

    Once a cut is passed, PROLOG will not backtrack to try other choices made before it in that clause.

    Find Tutors

    View all Tutors