Create 10 different Random numbers

Below is the program in C language that will create and display 10 different random numbers.
This program will make use of srand function in C.

In order to generate random numbers, srand is usually initialized to some distinctive value. We will also make use of time function as time function will return different value at different time. The value returned by the time function will act as a parameter to srand function.

Here is the code…

You may also like...

2 Responses

  1. great use of rand function
    Thanks

  2. Reshma K C says:

    can anyone plz post the ans for same qstn using pointers?????

Leave a Reply

Your email address will not be published. Required fields are marked *