Class Count

All Implemented Interfaces:
ArithFunction, Serializable

public class Count extends DefaultArithFunction

Function: .count(B): counts the number of occurrences of a particular belief (pattern) in the agent's belief base, as the internal action .count.

Example:

  • .count(a(2,_)): returns the number of beliefs that unify with a(2,_).
See Also: