int func(x)
int x;
{
.............
What is this kind of declaration called?
When is it valid/invalid including C or C++, certain standa
It's a function prototype. If you didn't do it this way you'd have to write the function out entirely before main, otherwise the compiler wouldn't know what the function was when you used it in main. It's not very descriptive, so it's not used anymore. You'd want to use something like:
int someFunction(int someParamX int someParamY);