All of us know very well,what a random number is??Most of you know how to generate random numbers using C/C++,And you may also have observed that the method you used to generate a random number(i.e.Use of rand() function) generates the same answer every time you run the program. The reason behind generation of the same random number is the seed value which is being used by your program doesn't change.A seed value is a special number which determines where the random number generator should start generating values.If you don’t seed the random number generator, it will generate the same exact sequence of numbers every time you run it. Hence instead of using normal rand() function in C/C++,you should use srand() function to generate a random number.But this srand() function must be provided with a non constant seed value,so that it will become a pure random geneartor function,and the best non constant seed value will be system time,hence we will use time(0) function which returns current system time which will be always non-constant. Hence,to generate a a pure random number in C/C++,we should use srand(time(0)) function,and we all know to generate a random number in the given range we will use modulo.