Thanks for any help you can give on this, I have spent many hours looking at what I'm doing wrong. I have searched the web, read, books, and talked to a friend with more experience about and we all at a loss.
I'm getting 1 error, sometimes after some adjustment the error changes so I put both of them below so maybe someone can explain them too me.
error C2064: term dose not evaluate to a function taking 1 argument
error C3861: 'time': identifier not found
Thanks for all the help you all can give.
#include <cstdlib>
#include <ctime>
#include "stdafx.h"
#include <Iostream>
int _tmain(int argc, _TCHAR* argv[])
{
using namespace std;
int x;
srand(time(0)); //The point of the problem
x = rand() % 100 +1; //Random number generated
if (x <= 49)
{
cout << "X is below the average." << endl;
}
if (x >= 50)
{
cout << "X is above the average." << endl;
}
else {
}
cin.get();
cin.get();
return 0;
}
I'm getting 1 error, sometimes after some adjustment the error changes so I put both of them below so maybe someone can explain them too me.
error C2064: term dose not evaluate to a function taking 1 argument
error C3861: 'time': identifier not found
Thanks for all the help you all can give.