Base Two | #. 1 1 1 | Base |
#.y is the base-2 value of y,
that is, 2#.y . For example:#. 1 0 1 0 10 #. 2 3$ 0 0 1,1 0 1 1 5 |
x#.y is a weighted sum of the items of y ;
that is, +/w*y , where w is the product
scan */\.}.x,1 . An atomic argument is reshaped
to the shape of the other argument.
|
]a=: i. 3 4 0 1 2 3 4 5 6 7 8 9 10 11 10 #.a 123 4567 9011 8 #. a 83 2423 4763 ]time=: 0 1 3,1 1 3,:2 4 6 0 1 3 1 1 3 2 4 6 x=: 24 60 60 x #. time 63 3663 7446 x,1 24 60 60 1 ]w=: */\.}. x,1 3600 60 1 w *"1 time 0 60 3 3600 60 3 7200 240 6 +/"1 w *"1 time 63 3663 7446 w +/@:* "1 time 63 3663 7446 c=: 3 1 4 2 [ y=: 0 1 2 3 4 5 c p. y Polynomial with coefficients c 3 10 37 96 199 358 y #."0 1 |.c 3 10 37 96 199 358