Function pointers as parameters in C++?
<p>I am confused by the form of parameters for function pointers. The following two:</p>

<pre><code>int fun(int (*g)())
{
    cout &lt;&lt; g() &lt;&lt; endl;
}

int fun(int g())
{
    cout &lt;&lt; g() &lt;&lt; endl;
}
</code></pre>

<p>Both these two definitions work well. But as you have noticed, there are some differences in the prototypes of these two functions:</p>

<ul>
<li>the first one takes parameter <code>int (*g)()</code>,</li>
<li>while the second takes parameter <code>int g()</code>.</li>
</ul>

<p>My question is are there any difference between them?</p>
