tests whether the argument is an atom or a number.
atomic/1 succeeds if Term is an atom or a number otherwise it fails.
Term term
| atomic('this is an atom'). | Succeeds. |
| atomic(15.27). | Succeeds. |
| atomic(Var). | Fails. |
| atomic(f(x,y)). | Fails. |
This predicate is part of the ISO-Prolog Standard.
| scroll to top |
|