JAMIA 2023 — Computer PYQ
JAMIA | Computer | 2023Give output of following C code:
int count (unsigned x)
{
int b;
for(𝑏=0;𝑥!=0;𝑥≫=1)
if(x & 01)
b++;
return b;
}
int main()
{
unsigned int a=3;
printf(“%d”, count(a));
return 0;
}

Give output of following C code:
int count (unsigned x)
{
int b;
for(𝑏=0;𝑥!=0;𝑥≫=1)
if(x & 01)
b++;
return b;
}
int main()
{
unsigned int a=3;
printf(“%d”, count(a));
return 0;
}