You can't have executable code outside of a function body. Move those parts to main():
int random_event_number;
int main()
{
srand(time(NULL));
random_event_number = rand() % 100 + 1;
....
}
Narue
Bad Cop
15,460 posts since Sep 2004
Reputation Points: 6,464
Solved Threads: 1,401