none
Small Basic Homework RRS feed

  • Question

  • so my school set some homework on small basic that i am really struggling with. you have to generate two random numbers and then use those numbers in a question. for example, if it generated 7 and 48 i could do 7*48. however, it generates new numbers rather than using the originals. can any1 help?
    Thursday, April 5, 2018 2:30 PM

Answers

  • May This Help You

    Max = 100
    number1=Math.GetRandomNumber(Max)
    number2=Math.GetRandomNumber(Max)
    TextWindow.WriteLine("Random1="+number1)
    TextWindow.WriteLine("Random2="+number2)
    TextWindow.WriteLine("Product="+number1*number2)
    TextWindow.Read()
    Best Regards
    Vikram Manjare
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread.

    Thursday, April 5, 2018 2:48 PM