While browsing a c++ faq I came across this comparison with C and found something I either didn't know or am reading wrong.
Code:
[6.11] Is C++ backward compatible with ANSI/ISO C?
Almost.
C++ is as close as possible to compatible with C, but no closer. In practice, the major difference is that C++ requires prototypes, and that f() declares a function that takes no parameters (in C, a function declared using f() can be passed an arbitrary number of parameters of arbitrary types).
Is this saying that defining a function as something like
Code:
void f();
/*...*/
void f(){
/*...*/
}
would let one do something like
or
Code:
f("string", NUM, 2);
or whatever? If so how do you refer to each argument in the function?