24. Consider the following C++ function f() :
unsigned int f(unsigned int n)
{
unsigned int b=0;
while(n)
{
b+=n&1;
n>>=1;
}
return b;
}
The function f() returns the int that represents the___p___in the binary representation of positive integer n, where P is
unsigned int f(unsigned int n)
{
unsigned int b=0;
while(n)
{
b+=n&1;
n>>=1;
}
return b;
}
The function f() returns the int that represents the___p___in the binary representation of positive integer n, where P is
ANS. D
Previous | Next |
UGC NET CS 2018 July - II Question 23 | UGC NET CS 2018 July - II Question 25 |
No comments:
Post a Comment