/usr/share/axiom-20170501/input/stream.input is in axiom-test 20170501-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | )set break resume
)spool stream.output
)set message test on
)set message auto off
)clear all
--S 1 of 12
ints := [i for i in 0..]
--R
--R
--R (1) [0,1,2,3,4,5,6,7,8,9,...]
--R Type: Stream(NonNegativeInteger)
--E 1
--S 2 of 12
f : List INT -> List INT
--R
--R Type: Void
--E 2
--S 3 of 12
f x == [x.1 + x.2, x.1]
--R
--R Type: Void
--E 3
--S 4 of 12
fibs := [i.2 for i in [generate(f,[1,1])]]
--R
--R Compiling function f with type List(Integer) -> List(Integer)
--R
--R (4) [1,1,2,3,5,8,13,21,34,55,...]
--R Type: Stream(Integer)
--E 4
--S 5 of 12
[i for i in ints | odd? i]
--R
--R
--R (5) [1,3,5,7,9,11,13,15,17,19,...]
--R Type: Stream(NonNegativeInteger)
--E 5
--S 6 of 12
odds := [2*i+1 for i in ints]
--R
--R
--R (6) [1,3,5,7,9,11,13,15,17,19,...]
--R Type: Stream(NonNegativeInteger)
--E 6
--S 7 of 12
scan(0,+,odds)
--R
--R
--R (7) [1,4,9,16,25,36,49,64,81,100,...]
--R Type: Stream(NonNegativeInteger)
--E 7
--S 8 of 12
[i*j for i in ints for j in odds]
--R
--R
--R (8) [0,3,10,21,36,55,78,105,136,171,...]
--R Type: Stream(NonNegativeInteger)
--E 8
--S 9 of 12
map(*,ints,odds)
--R
--R
--R (9) [0,3,10,21,36,55,78,105,136,171,...]
--R Type: Stream(NonNegativeInteger)
--E 9
--S 10 of 12
first ints
--R
--R
--R (10) 0
--R Type: NonNegativeInteger
--E 10
--S 11 of 12
rest ints
--R
--R
--R (11) [1,2,3,4,5,6,7,8,9,10,...]
--R Type: Stream(NonNegativeInteger)
--E 11
--S 12 of 12
fibs 20
--R
--R
--R (12) 6765
--R Type: PositiveInteger
--E 12
)spool
)lisp (bye)
|