Menu

RDM

Mona B
2017-08-27
2017-08-27
  • Mona B

    Mona B - 2017-08-27

    I'm following a simple tutorial that uses this code to get a random number between 1 and 20:

    10 CLS
    20 PRINT INT(RND(1)*20+1)
    

    When I run it, it gets the random number. When I run it again, it gets the same no-longer-random number. No matter how many times I run it, I get the same number.

    Is it supposed to work this way? Is there something I'm misunderstanding?

     
  • Mona B

    Mona B - 2017-08-27

    Nevermind, within the loop it does what it is supposed to do.