How to write a code for random pick from 1-1000 numbers?
The output should contain the 10 numbers from the range
1-1000 which should pick randomly, ie ,for each time we run
the code we should get different outputs.
Answer Posted / sharan
if the randomize(); doesn't work
replace it with srand ((unsigned) time (NULL));
Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
What is the explanation for prototype function in c?
void main(){ int a; a=1; while(a-->=1) while(a-->=0); printf("%d",a); }
What is a wrapper function in c?
Difference between malloc() and calloc() function?
What are reserved words?
Can include files be nested?
How main function is called in c?
What is a macro in c preprocessor?
Explain how do you use a pointer to a function?
Hai sir, I had planned to write the NIC scientific engineer exam , plz post the sample question......
I just typed in this program, and it is acting strangely. Can you see anything wrong with it?
Explain c preprocessor?
In C language, the variables NAME, name, and Name are all the same. TRUE or FALSE?
What are 'near' and 'far' pointers?
Why do we need a structure?