Advertisement
_no0B

Untitled

Dec 31st, 2021
1,010
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.44 KB | None | 0 0
  1. #include<bits/stdc++.h>
  2. #define LL long long
  3. #define N ((int)1e5 + 8)
  4. #define MAX ((int)1e9 + 8)
  5. #define fastio ios_base::sync_with_stdio(false),cin.tie(NULL)
  6.  
  7. using namespace std;
  8.  
  9. mt19937 rng(chrono::steady_clock::now().time_since_epoch().count()); // generator
  10.  
  11.  
  12. int GetRandomNumber(int a , int b)
  13. {
  14.     return uniform_int_distribution<int>(a, b)(rng); //rand([a,b])
  15. }
  16.  
  17.  
  18.  
  19. int main()
  20. {
  21.     cout<<GetRandomNumber(0 , 100)<<endl;
  22. }
  23.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement