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

What is the output of the following code:
int v()
{
int m=0;
return m++;
}
int main()
{
cout<<v();
}




1) 1


2) 0


3) Code cannot compile

Answer Posted / shailaja

the output of this code is

0
bcz here the return statement it will stops the execution
and returns to the calling function.

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is class encapsulation?

1034


Write A Program to find the ambiguities in Multiple Inheritance? How are they resolved.(Virtual Functions)

4089


What is Difference Between Inheritance and creating object and getting data? means Class A extends B{ B.getMethod();} (OR) Class A{ b obj=new B(); obj.getMethod(); }

2508


i got a backdoor offer in process global,Bangalore..Can i work with it?

2800


What is polymorphism explain its types?

1105


Can we override main method?

1137


What is inheritance and how many types of inheritance?

1049


What are the data types in oop?

1050


What is interface? When and where is it used?

2115


What causes polymorphism?

1074


What does sksksk mean in text slang?

2064


write a C++ program for booking using constructor and destructor.

2499


Prepare me a program for the animation of train

2424


What is the significance of classes in oop?

1072


when to use 'mutable' keyword and when to use 'const cast' in c++

2118