Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #include <time.h>
- #define SIZE 1000000
- /* Author: pppoe2345 */
- int main (int argc, char *argv[])
- {
- FILE *outfile;
- char *outfile_name = "input";
- unsigned long i, num, select;
- srand (time (NULL));
- outfile = fopen (outfile_name, "w");
- for (i = 0; i < SIZE; i++)
- {
- select = rand () & 1;
- num = (select << 31) | rand ();
- fprintf (outfile, "%lu\n", num);
- }
- fclose (outfile);
- return 0;
- }
Add Comment
Please, Sign In to add comment