It is possible to check more than one condition at the same time. You just chain them together, with the words "and" and "or". Example:

if ((the hit ship only had one field left)
and (there was only one ship left))
  appoint a winner

if ((this field belongs to player A)
or (this field belongs to player B))
  there shouldn't be water here

Concept last updated: 24/09 2003.


is a

Other sources

Adfærdsmønster And/or Array