hai

there was a typographical error in the printf statement.

here is the modified version

 

#include <stdio.h>

 int main()

 {

         char c[5];

         int i;

         c[0]='A';

 

         sprintf(c+1,"%d%d%d%d",3,4,2,2);

         printf("size of char array = %d\n",sizeof(c));

         printf("%s\n",c);

      

 }

with regards

pradap

 

 


From: Pradap [mailto:[EMAIL PROTECTED]]
Sent: Friday, October 22, 2004 2:29 PM
To: [EMAIL PROTECTED]
Subject: RE: (PT) help

 

hai

try this code

#include <stdio.h>

 int main()

 {

         char c[5];

         int i;

         c[0]='A';

 

         sprintf(c+1,"%d%d%d%d",3,4,2,2);

         printf("size of char array = %d\n",s);

         printf("%s\n",c);

      

 }

with regards

pradap

 

 


From: soewandi_w [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 21, 2004 8:20 PM
To: [EMAIL PROTECTED]
Subject: (PT) help

 



Does anyone know how to make this thing works?

for example

    char   int  int  int  int
    'A'     3    4   2    2

to be in char type with 5 bytes total .. in C btw .. i tried to use
memcpy, but i don't think it works ...








To unsubscribe : [EMAIL PROTECTED]






To unsubscribe : [EMAIL PROTECTED]







To unsubscribe : [EMAIL PROTECTED]




Yahoo! Groups Sponsor
ADVERTISEMENT
click here
Web Bug from http://us.adserver.yahoo.com/l?M=295196.4901138.6071305.3001176/D=groups/S=:HM/A=2128215/rand=734802355


Yahoo! Groups Links

Reply via email to