+ 5
Suppose you need to get a random no from 7,8 or 9 into your phone number as the first digit
So the best way will be to store the number in an array.
int no[10];//C++
And randomly determine every number.
Using rand();//C++ code
And to limit rand() to a range, use the following format-:
(rand()%U)+L;
//U=Upper Limit
//L=Lower Limit
And here it will be -:
(rand()%9)+7;



