A C/C++ Function Call Puzzle
Consider the following program. Predict the output of it when compiled with C and C++ compilers.
The above program compiles fine in C, but doesn’t compile in C++.
In C++, func() is equivalent to func(void)
In C, func() is equivalent to func(…)
This article is compiled by Rahul Mittalal. If you like GeeksforGeeks and would like to contribute, you can also write an article and mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.