SyntaxFix
Write A Post
Hire A Developer
Questions
void foo(void) is better because it explicitly says: no parameters allowed.
void foo(void)
void foo() means you could (under some compilers) send parameters, at least if this is the declaration of your function rather than its definition.
void foo()