repo.or.cz
/
io
/
quag.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Removed all code that uses OpenGL from Image.
[io/quag.git]
/
addons
/
Rational
/
samples
/
Sample.io
blob
856659f043df592677e45eed963b59c685a7d618
1
#!/
usr
/
bin
/
env io
2
3
/* Example usages of Rational Numbers */
4
5
r1
:=
Rational
with
(
1
,
2
)
/* 1/2 */
6
r1
+
r1
==
Rational
with
(
1
,
1
)
/* true */
7
Rational
with
(
1
,
1
) ==
Rational
with
(
4
,
4
)
/* true */
8
9
r2
:=
Rational
with
(
1
,
4
)
10
r1
+
r2
==
0.75
asRational