Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What are bit fields? What is their use?

Answer Posted / vadivel t

Bit fields main intention is to reduce the memory
consumption.

Syntax:
------

struct
{
int a:1;
/*whatever may be the size of the int(compiler dependent),
only one bit shall be allocated for variable 'a'*/
}BITFIELDS;

Restictions:
------------
1. Accessing or printing address of bitfield variable is
not possible.
2.Array of bit fields, not possible.
3.A function cannot return a bit field variable.

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which type of language is c?

1079


What is the size of enum in bytes?

1091


What is the process of writing the null pointer?

1030


hi to every one .. how to view table pool after creating the pooled table? plz help me.. if any knows abt this ..

1925


What is difference between union and structure in c?

1170


Why is this loop always executing once?

1061


Subtract Two Number Without Using Subtraction Operator

854


What are Macros? What are its advantages and disadvantages?

1168


What is c token?

1073


Do you know the difference between malloc() and calloc() function?

1069


In c language can we compile a program without main() function?

1138


Write a factorial program using C.

1087


What is a constant?

1065


Describe the steps to insert data into a singly linked list.

1077


ATM machine and railway reservation class/object diagram

5253