Hacker News new | past | comments | ask | show | jobs | submit login

> The :- means if and only if, or iff.

Is it really the case?

  Human("Socrates").
  Animal("Turtle").
  Mortal(x) :- Human(x).
  Mortal(x) :- Animal(x).
Suppose :- means iff. Turtle is Mortal (lines 2+4, implication to the left). Because Turtle is Mortal, it must be a Human (line 3, implication to the right).

Is it really valid according to Datalog semantics?




Hi! Thank you for highlighting this.

No, you and sdbrady who commented above are correct; the :- only means "if". I have edited accordingly and apologise for the misunderstanding!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: