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

Evaluate:
int fn(int v)
{
if(v==1 || v==0)
return 1;
if(v%2==0)
return fn(v/2)+2;
else
return fn(v-1)+3;
}
for fn(7);

a) 10
b) 11
c) 1

Answer Posted / rajesh

b

Is This Answer Correct ?    8 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Are strings immutable in c++?

1160


What is the difference between a template and a macro?

1067


How can we check whether the contents of two structure variables are same or not?

1073


You run a shell on unix system. How would you tell which shell are you running?

1173


What is the meaning of c++?

1029


Describe the setting up of my member functions to avoid overriding by the derived class?

1135


Define private, protected and public access control.

1123


Define a nested class.

1078


What do you mean by enumerated data type?

1051


Describe the advantages of operator overloading?

1048


State the difference between pre and post increment/decrement operations.

1081


Where is atoi defined?

1144


Explain the auto storage classes in c++.

1103


Which software is used for c++ programming?

1082


What are virtual functions in c++?

1185