the link ll not occupy any m/y here...so its output ll be 14(int -4 bytes,ptr-2 bytes);;if i'm wrong jst crct it...
On 7/26/11, Prem Krishna Chettri <hprem...@gmail.com> wrote: > Its Cos that is pointer and all pointers is 4 bytes address.. > > On Tue, Jul 26, 2011 at 7:11 PM, Puneet Gautam > <puneet.nsi...@gmail.com>wrote: > >> @everyone: >> I have this mind strangling doubt..!!! >> >> Why is "char *s[5]" of 20 bytes...? >> >> yes the output is 28... >> >> On 7/26/11, Don <dondod...@gmail.com> wrote: >> > A reasonable guess would be 28 bytes. But the size of a structure is >> > implementation dependent, and therefore, some other result could be >> > correct as well. >> > Don >> > >> > On Jul 26, 7:40 am, Puneet Gautam <puneet.nsi...@gmail.com> wrote: >> >> #include<stdio.h> >> >> #include<stddef.h> >> >> struct node{ >> >> int a; >> >> char *b[5]; >> >> struct node *link; >> >> }; >> >> main() >> >> { >> >> int a; >> >> a=sizeof(struct node); >> >> printf("%d",a); >> >> getchar(); >> >> return 0; >> >> } >> >> >> >> Whats the output..? >> > >> > -- >> > You received this message because you are subscribed to the Google >> > Groups >> > "Algorithm Geeks" group. >> > To post to this group, send email to algogeeks@googlegroups.com. >> > To unsubscribe from this group, send email to >> > algogeeks+unsubscr...@googlegroups.com. >> > For more options, visit this group at >> > http://groups.google.com/group/algogeeks?hl=en. >> > >> > >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Algorithm Geeks" group. >> To post to this group, send email to algogeeks@googlegroups.com. >> To unsubscribe from this group, send email to >> algogeeks+unsubscr...@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/algogeeks?hl=en. >> >> > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to algogeeks@googlegroups.com. > To unsubscribe from this group, send email to > algogeeks+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > > -- //BE COOL// kavi -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.