Am I able to complement a virtual function of subclasses? : <p>i have a question. Lets say i have this virtual function in main class:</p>

<pre><code>virtual void h_w() { cout &lt;&lt; "Hello, wolrd!" &lt;&lt; endl; }
</code></pre>

<p>And Im doing with the same function that:</p>

<pre><code>void h_w() { cout &lt;&lt; "Today is: " &lt;&lt; math.rand(); &lt;&lt; endl; }
</code></pre>

<p>Am I allowed to do that? I mean, can i change body of main function like I want in subclasses? Thanks.</p>
