Skip to content

Instantly share code, notes, and snippets.

@amankharwal
Created Nov 25, 2020
Embed
What would you like to do?
#include<iostream>
#include<cstdlib>
using namespace std;
int main(){
unsigned int seed;
int z1, z2, z3;
cout<<" Random Numbers"<<endl;
cin>>seed;
srand(seed);
z1 = rand();
z2 = rand();
z3 = rand();
cout<<"Three random numbers :"<<z1<<" "<<z2<<" "<<z3<<endl;
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment