Determine how may bytes are needed to store a structure of type hair_info_t, assuming two bytes for an integer and one byte for a character - counter
Sponsored Links


Popular Links


List of Abbreviations

National Highways in India

States & Union Territories of India

Currency of All Countries

Determine how may bytes are needed to store a structure of type hair_info_t, assuming two bytes for an integer and one byte for a character

You are Here: Home > Computer Subjects > Programming in C Language > …

Determine how may bytes are needed to store a structure of type hair_info_t, assuming two bytes for an integer and one byte for a character.

Ans. Suppose the structure looks like:

     struct hair_info_t
     {
         int a;
         int b;
         char c;
     }

Then two Integer will take 2 + 2 = 4 byte of memory and the Character will take 1 byte of Memory. So, the total memory require is: 2 + 2 + 1 = 5 byte.

 

Click Here to Find Latest Jobs and Current Affairs

Updated: May 31, 2013 — 2:06 pm

Leave a Reply

Your email address will not be published. Required fields are marked *

© 2016. All Rights Reserved. WikiIND.com