Post History
Dyalog APL, 2 bytes ?⍴ Dyadic 2-train, takes $n$ as its left argument and $m$ as its right argument The Roll function ? expects an array of maximum bounds and replaces each item with a random ...
Answer
#1: Initial revision
# Dyalog APL, 2 bytes ```apl ?⍴ ``` Dyadic 2-train, takes $n$ as its left argument and $m$ as its right argument The Roll function `?` expects an array of maximum bounds and replaces each item with a random number between 1 and that bound (ie `?2 6 5` returns `(random between 1 and 2) (random between 1 and 6) (random between 1 and 5)`. Reshape `⍴` is used to convert $n$ and $m$ to the list $[m, m, \dots(n\text{ times}), m]$.