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

What is the difference between volatile and const volatile?

982


What are operators in c?

1022


A function can make the value of a variable available to another by a) declaring the variable as global variable b) Passing the variable as a parameter to the second function c) Either of the two methods in (A) and (B) d) binary stream

1160


A collection of functions,calls,subroutines or other data a) library b) header files c) set of files d) textfiles

1170


What is a shell structure examples?

1090


What do you mean by invalid pointer arithmetic?

1067


Sir i need notes for structure,functions,pointers in c language can you help me please

2403


Write a program to swap two numbers without using the third variable?

1060


What are the features of c language?

1061


Hi can anyone tell what is a start up code?

2058


What is the function of multilevel pointer in c?

1077


What is the purpose of main() function?

1241


What are the types of assignment statements?

1060


What is the difference between declaring a variable by constant keyword and #define ing that variable?

3353


Tell us bitwise shift operators?

1089