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

What is c++ programming language?

1087


What is an adaptor class or wrapper class in c++?

1176


Is c++ primer good for beginners?

1026


What is a virtual destructor? Explain the use of it?

980


Tell me what are static member functions?

1071


Explain object slicing in c++?

1042


What is general format for a prototype?

1030


What are the various storage classes in C++?

1124


What is a container class? What are the types of container classes in c++?

1237


What is insertion sorting?

1093


How did c++ start?

1075


Explain the static member function.

1164


How do I run c++?

1050


Why c++ is not a pure oop language?

1022


Implement stack operations with pointers with appropriate exception checks.

961