Functions with no arguments
C++
No need to use the word void when declaring or defining a
function with no arguments.
void draw (void); /* no arguments in C */
void draw (); /* variable parameters */
void draw (); // no arguments in C++

C++ allows function arguments to have default values. The
following function prints N newline chars, but if no
parameter is passed, then a default of 1 is used.

void new_line (int N = 1) // default argument
{
while (N-- > 0)
putchar ('\n');
}
with invocation:
new_line (3); // prints 3 blank lines
new_line (); // 1 blank line by default

This is a significant difference.

In C to pass back a result through a parameter you must
provide a pointer to the location where the result is to
go (the pointer itself does not change) thus we write
scanf ("%d", &N);
|