| Format | floattoint(+IN,+OUT) | |||
|---|---|---|---|---|
| Arguments |
| |||
| Convert float IN to integer OUT. | ||||
| Format | floor(+$NUM1,-$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Get the maximum integer under $NUM1 to $NUM2. | |||||||
| Format | log(+NUM,-LOG) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Return logarithm of number NUM. | |||||||
| Format | exp(+NUM,-LOG) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Return exponent of number NUM. | |||||||
| Format | '/\'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get the $NUM1 AND $NUM2 to $ANS. | ||||||||||
| Format | '\/'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get the $NUM1 OR $NUM2 to $ANS. | ||||||||||
| Format | '#'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get the $NUM1 XOR $NUM2 to $ANS. | ||||||||||
| Format | '\'(+$NUM,-$ANS) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Get the NOT $NUM to $ANS. | |||||||
| Format | '+'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get the result of "$NUM1 + $NUM2" to $ANS.This can be apply to strings. | ||||||||||
> ?- '+'(3,5.5,8.5).
yes
> ?- '+'(-10,5,X).
X: -5
> ?- '+'("abc","def",X).
X: "abcdef"
| ||||||||||
| Format | '-'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get result of "$NUM1 - $NUM2" to $ANS. | ||||||||||
> ?- '-'(3,5.5,X). X: -2.50000 | ||||||||||
| Format | '*'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get result of "$NUM1 * $NUM2" to $ANS. | ||||||||||
> ?- '*'(2,-6,X). X: -12 | ||||||||||
| Format | '/'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get result of "$NUM1 / $NUM2" to $ANS. | ||||||||||
> ?- '/'(2,-6,X). X: -0.333333 | ||||||||||
| Format | '//'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get integer result of "$NUM1 / $NUM2" to $ANS. | ||||||||||
> ?- '//'(36,5,X). X: 5 | ||||||||||
| Format | '///'(+$NUM1,+$NUM2,-$ANS) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Arguments |
| |||||||||
| Get reminder of integer division "$NUM1 / $NUM2" to $ANS. | ||||||||||
> ?- mod(36,5,X). X: 1 | ||||||||||
| Format | '>'(+$NUM1,+$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Success if $NUM1 is larger than $NUM2. | |||||||
> ?- '>'(5.6,6).
no
> ?- '>'("abc","abC").
yes
| |||||||
| Format | '>='(+$NUM1,+$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Success if $NUM1 is larger than $NUM2 or equal to $NUM2. | |||||||
> ?- '>='(5.6,6).
no
> ?- '>='("abc","abC").
yes
| |||||||
| Format | '<'(+$NUM1,+$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Success if $NUM1 is smaller than $NUM2. | |||||||
> ?- '<'(5.6,6).
yes
> ?- '<'("abc","abC").
no
| |||||||
| Format | '<='(+$NUM1,+$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Success if $NUM1 is smaller than $NUM2 or equal to $NUM2. | |||||||
> ?- '<='(5.6,6).
yes
> ?- '>'("abc","abC").
no
| |||||||
| Format | '=:='(+$NUM1,+$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Success if $NUM1 is equal to $NUM2. | |||||||
| Format | '=\='(+$NUM1,+$NUM2) | ||||||
|---|---|---|---|---|---|---|---|
| Arguments |
| ||||||
| Success if $NUM1 is not equal to $NUM2. | |||||||