Jan 17, 2009

how will u determine size of a numeric variable??

how will u determine size of a numeric variable??
soln:(X be a numeric type)
X n=1;
int i=0;
while(n)
{
n<<=1;
i++;
}
return i;

No comments:

Post a Comment