hello,<br><br>In c++, can we define a constructor in a .h extension file? we can obviously declare the constructor and the functions in the .h file extension but can we define it also?<br><br>regards,<br><br>sunny_slls<br>
<br><div class="gmail_quote">On Sat, Dec 26, 2009 at 5:26 PM, Sunny Sharma <span dir="ltr"><<a href="mailto:sunny20062010@gmail.com">sunny20062010@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Got it. actually it slipped from my eyes :) thanks<div><div></div><div class="h5"><br><br><div class="gmail_quote">On Sat, Dec 26, 2009 at 3:14 PM, Aanjhan R <span dir="ltr"><<a href="mailto:aanjhan@gmail.com" target="_blank">aanjhan@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div>On Sat, Dec 26, 2009 at 4:10 AM, Sunny Sharma <<a href="mailto:sunny20062010@gmail.com" target="_blank">sunny20062010@gmail.com</a>> wrote:<br>


> oh no! then it is creating a problem...never mind. well there is another one<br>
> if   int x = 1, y = 1;<br>
> printf("%d",printf("%d%d",x,y));<br>
><br>
> the output is coming 1 12 can you explain me how?<br>
<br>
</div>Yes it is correct!<br>
<br>
printf operated in this way if it is used within another printf.<br>
<br>
Lets take the innermost printf<br>
<br>
printf("%d",x,y) -> is printed as 11 (clear)<br>
<br>
the outer printf now works a bit tricky.<br>
<br>
printf("%d", <previousprintfoutput>)<br>
<br>
Now this printf prints the length of the characters printed by the<br>
inner printf i.e two.<br>
<br>
The net output is now 112 which is what you get.<br>
<br>
If you modify the code to be something like printf("%d",printf("%d\t%d", x, y))<br>
<br>
You will get 113 as output as \t is another character.<br>
<br>
Hope it helps.<br>
<font color="#888888"><br>
Aanjhan<br>
</font><div><div></div><div>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.dgplug.org" target="_blank">Users@lists.dgplug.org</a><br>
<a href="http://lists.dgplug.org/listinfo.cgi/users-dgplug.org" target="_blank">http://lists.dgplug.org/listinfo.cgi/users-dgplug.org</a><br>
</div></div></blockquote></div><br>
</div></div></blockquote></div><br>