APL Exercises 6
Key Operator
⎕io←0 throughout.
6.0 Drills
Predict the result of each expression before evaluating it.
x←'Mississippi' |
y←10+11 2⍴⍳22 |
{⍺⍵}⌸x |
{⍺ (≢⍵)}⌸x |
{≢⍵}⌸x |
{⍺}⌸x |
|
x{⍺⍵}⌸y |
x{⍺ (≢⍵)}⌸y |
x{≢⍵}⌸y |
x{⍺}⌸y |
x{⍺(+/,⍵)}⌸y |
x{⍺(⌈/,⍵)}⌸y |
x{⍺(⌊/,⍵)}⌸y |
|
x←?1e4⍴100 |
¯1+{≢⍵}⌸(⍳100),x |
+/(⍳100)∘.=x |
|