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...

how to find the size of the data type like int,float
without using the sizeof operator?

Answer Posted / ravi.jnv

Its possible by pointers.
-----------------
int one,two;
int *ptrOfOne,*ptrOfTwo;
int size;
ptrOfOne = &one;
ptrOfTwo = &two;
size = ptrOfOne - ptrOfTwo ; /* u can get minus value also
depending upon stack how it pushes variables */

Is This Answer Correct ?    6 Yes 28 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How important is structure in life?

1044


What is atoi and atof in c?

1048


What is the use of header?

1069


What is null pointer constant?

1092


If errno contains a nonzero number, is there an error?

1323


How can I handle floating-point exceptions gracefully?

1129


Write a program to show the change in position of a cursor using c

1015


What is this pointer in c plus plus?

1044


What is operator precedence?

1163


What's the difference between constant char *p and char * constant p?

1108


Not all reserved words are written in lowercase. TRUE or FALSE?

1198


how to write optimum code to divide a 50 digit number with a 25 digit number??

3226


What is assignment operator?

1023


Why c is called top down?

1109


Why is c so powerful?

1079