" <-APL2-------------------- sam231.txt ----------------------------> " <- bracket index -------------------------------------------------> Lio#0 'curtail'[0 1 3] Lio#1 'curtail'[1 2 4] " <- when a vector is indexed --------------------------------------> a#23 9 6.3 8 -3 7 L#z#a[3] Rz L#z#a[2 5 1] Rz L#b#2 3R1 4 3 2 6 5 L#q#a[b] Rq " <- when a matrix is indexed --------------------------------------> L#c#3 6R'abcdefghijklmnopqr' L#j#c[2;3] Rj L#p#c[1;3 1 4] Rp L#m#c[1 2;1 3] Rm L#n#c[1 3;2 3R6 1 3 4 5 2] Rn " <- eliding index arrays ------------------------------------------> L#d#3 4Rc[1 2;] d[;1] d[3;] " <- repetitions of index values -----------------------------------> L#h#2 4R3 4 1 2 2 3 4 1 'emit'[h] 'nab'[3 2 1 2 1 2] " <- when a higher-rank array is indexed ---------------------------> L#u#2 3 4R(,c),'stuvwx' u[1;2;4] u[2;1;1 3 4] u[;2;4] u[1;1 3;2 4] u[1;;3] u[2;1;] u[;3;] " <- when a nested array is indexed --------------------------------> L#v#'h' 'hi' ('him' 'his') L#z#v[1] `=z RRz L#e#v[2] `=e L#s#v[3] `=s RRs " <- selective specification ---------------------------------------> Rv `=v v[3]#'h' v `=v w#2 3R'abcdef' w[1;1 3]#8 9 w b#3 4 5 b[]#9 b )off