Skip to content

Commit cafec92

Browse files
committed
Add INT doc
Fixes #504
1 parent 3c2c289 commit cafec92

1 file changed

Lines changed: 32 additions & 0 deletions

File tree

docs/int.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
#INT
2+
3+
##Syntax
4+
5+
6+
```
7+
INT(numericExpression)
8+
```
9+
10+
11+
##Description
12+
13+
Rounds the given expression by truncation. This function behaves
14+
exactly like the one in the Sinclair BASIC ROM.
15+
Argument must be a numeric expression. Returned value is a long (32 bit) number
16+
that will be casted (converted) to the required type.
17+
18+
##Examples
19+
20+
21+
```
22+
REM Round by truncation
23+
LET a = 1.5
24+
PRINT "Int value of a is "; INT(a)
25+
REM 'Will print 1
26+
```
27+
28+
29+
##Remarks
30+
31+
* This function is 100% Sinclair BASIC Compatible
32+

0 commit comments

Comments
 (0)