Timeline for Cartesian product of a list with itself n times
Current License: CC BY-SA 4.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
May 29, 2018 at 19:56 | comment | added | ngn | the only catch is with ⍵=1, in that case ⍳ returns a plain vector, not a vector of nested length-1 vectors as one would expect; it's one of those bugs that never get fixed, for backwards-compatibility reasons | |
May 29, 2018 at 19:53 | history | edited | Adalynn | CC BY-SA 4.0 |
added 27 characters in body
|
May 29, 2018 at 19:48 | comment | added | ngn |
⍺[↑,⍳⍵⍴≢⍺]
|
|
May 29, 2018 at 19:40 | comment | added | Adalynn |
I got a RANK ERROR when I tried to do that.
|
|
May 29, 2018 at 19:35 | comment | added | ngn |
you can use ⍳ with a vector argument to generate indices and then ⍺[ ] to get the corresponding values
|
|
May 29, 2018 at 19:07 | history | answered | Adalynn | CC BY-SA 4.0 |