Advertisement
farsid

Untitled

Aug 8th, 2012
40
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. #define filer() freopen("in.txt","r",stdin)
  2. #define filew() freopen("in.txt","w",stdout)
  3. #define SET(a, x) memset((a), (x), sizeof(a))
  4. #define i64 long long
  5. #include<iostream>
  6. #include<stdio.h>
  7. #include<string.h>
  8. #include<math.h>
  9. #include<algorithm>
  10. #include<queue>
  11. #include<stack>
  12. #include<vector>
  13. #include <map>
  14. #define INF 1<<29
  15. #include<time.h>
  16. #include<stdlib.h>
  17.  
  18. using namespace std;
  19.  
  20.  
  21.  
  22. int main()
  23. {
  24. filew();
  25. int T,cas=0;
  26. printf("1000\n");
  27. for(int i=0;i<1000;i++)
  28. {
  29. printf("\n");
  30. unsigned long int d,guess;
  31. srand((unsigned int)(time(NULL)*time(NULL)));
  32. d=rand()%40000;
  33. printf("%d\n",d);
  34. for(i=0;i<d;i++)
  35. {
  36. unsigned long int x,y;
  37. srand((unsigned int)(time(NULL)*time(NULL)));
  38. x=rand()%10000000;
  39. srand((unsigned int)(time(NULL)*time(NULL)));
  40. y=rand()%(10000000-x);
  41. y+=x;
  42. printf("%d %d\n",x,y);
  43. }
  44. }
  45. return 0;
  46. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement