Symbol | Meaning | Example |
---|---|---|

+ | Addition | X is 1 + 2 |

- | Substraction | X is 1 - 2 |

* | Multiply | X is 3 * 2 |

/ | Real Divide | X is 7.0 / 3 |

// | Integer Divide | X is 7 // 3 |

mod | Modulo | X is 75 mod 12 |

EXAMPLES:

bonus(Number) :- Number is 2 + 3.

?bonus(D). => D = 5.

?bonus(3). => no.

?bonus(5). => yes.

CS1104
Main Page

Last Updated 03/28/2000

©
J.A.N. Lee, 2000