mbranco18
mbranco18

Reputation: 1

Why am I getting an existance error in prolog

I'm trying to call a function in prolog, and I keep getting the same error and I can't understand why.

(GameOption =:= 1 -> play_game(4); GameOption =:= 2 -> playgamevscomputer(4))
playgamevscomputer(X):-
    initial_board(X, Board),
    displaygamevscomputer(X, Board, red).

! Existence error in user:playgamevscomputer/1
! procedure user:playgamevscomputer/1 does not exist
! goal:  user:playgamevscomputer(4)

I tried changing the name, and body of the function but nothing seems to work

Upvotes: 0

Views: 59

Answers (0)

Related Questions