Julia 1.5.3 on Ubuntu. I'm trying to simply generate an array of four, Int8 integers, comprised of the range from 1:3. Tried a bunch of different syntax but just get errors. I can't control both the type (Int8), and the number or returns (4). Thx. J
rand(1:3, 4) # works
rand(Int8, 4) # works
rand(Int8, 1:3, 4) #error
rand(Int8, 4, 1:3) #error
rand(Int8(1:3), 3) #error
Aucun commentaire:
Enregistrer un commentaire