hello, i need to generate a random number smaller than 100. how can i do it. i found a rand() function but i can't specify the upper limit!
i also thought of making a function wich would generate a random nr (with the rand() function) and then check if that nr is smaller than 100, if it is then pass it to my int, if not generate another nr, but a think this may take a lot of time!