Professional Documents
Culture Documents
#include <cstdlib>
#include <ctime>
#include <iomanip>
using namespace std;
//Beniel Alonso
//83020
//Cesc 2200
//#10 Random Guessing Number
int main()
{
int x, num;
cout << setw(60) << "Random Number Program" << endl;
cout << endl;
cout << "You have to guess from 0 to 100" << endl;
cout << endl;
cout << "Enter a random numer: ";
cin >> num;
srand(time(NULL));
for (int i = 0; i < 100; i++)
{
x = (rand() % (100 - 1 + 1)) + 1;
}
do
{