next | previous | forward | backward | up | top | index | toc | Macaulay2 web site

random(ZZ,ZZ) -- random integer in a range

Synopsis

Description

i1 : for i to 10 list random(100,200)

o1 = {161, 168, 140, 115, 175, 143, 143, 180, 144, 119, 137}

o1 : List
i2 : tally apply(100, i -> random(10,15))

o2 = Tally{10 => 19}
           11 => 22
           12 => 16
           13 => 20
           14 => 13
           15 => 10

o2 : Tally

See also