Menu Fuction Not Calling

I'm trying to write a calculator app with functions and get back into the swing of things. but this simple bit of code just skips over hello world. Anyone any idea why?

1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <iostream>
using namespace std;


void menu()
{
	cout << "Hello World!" << endl;
}

int main()
{
	void menu();
	return 0;
}
remove void keyword from line 12.
that is not how you call a function.
http://www.cplusplus.com/doc/tutorial/functions/
Last edited on
Thanks, IDK how I missed that best do more reading up.
no worries dude. Just out of interest, your compiler was seeing line 12 as a function declaration, rather than a function call, which is why nothing was happening.
Ahhh makes sense!
Topic archived. No new replies allowed.