What is the maximum possible value of the following code | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What is the maximum possible value of the following code

Cout<<rand()%2+10;

11th Sep 2020, 1:56 PM
Pulasani Aswini
Pulasani Aswini - avatar
5 Answers
+ 5
nope u can easily google it 😉
11th Sep 2020, 2:08 PM
Oma Falk
Oma Falk - avatar
+ 4
11
11th Sep 2020, 1:59 PM
Oma Falk
Oma Falk - avatar
11th Sep 2020, 3:18 PM
Jayakrishna 🇮🇳
0
Can you explain what is rand() please
11th Sep 2020, 2:01 PM
Pulasani Aswini
Pulasani Aswini - avatar
0
rand() evaluates a random integer between 0 and 4 294 967 295 (unsigned long). The result is not truly random, you may notice getting identical results when you run the code again, but the lesson offers a good solution.
11th Sep 2020, 3:56 PM
Seb TheS
Seb TheS - avatar