Comments embedded...

> -----Original Message-----
> From: Pradap [mailto:[EMAIL PROTECTED] 
> Sent: Friday, October 22, 2004 3:59 AM
> To: [EMAIL PROTECTED]
> Subject: RE: (PT) help
>
> hai 
> try this code

Don't.  The code is incorrect...

> #include <stdio.h>
>�int main()
>�{
>�������� char c[5];
>�������� int i;
>�������� c[0]='A';
>
>�������� sprintf(c+1,"%d%d%d%d",3,4,2,2);

You've just overflow the 'c' array.  sprintf added a '\0' character to
terminate the string after the last character is written.


>�������� printf("size of char array = %d\n",s);
>�������� printf("%s\n",c);
>������ 
>�}
> with regards
> pradap

HTH
Shyan








------------------------ Yahoo! Groups Sponsor --------------------~--> 
$9.95 domain names from Yahoo!. Register anything.
http://us.click.yahoo.com/J8kdrA/y20IAA/yQLSAA/EbFolB/TM
--------------------------------------------------------------------~-> 

To unsubscribe : [EMAIL PROTECTED]

 
Yahoo! Groups Links

<*> To reply to this message, go to:
    http://groups.yahoo.com/group/Programmers-Town/post?act=reply&messageNum=3621
    Please do not reply to this message via email. More information here:
    http://help.yahoo.com/help/us/groups/messages/messages-23.html

<*> To visit your group on the web, go to:  
    http://groups.yahoo.com/group/Programmers-Town/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to