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


how is returning structurs from functions?Show an eg?



how is returning structurs from functions?Show an eg?..

Answer / ravi.g

struct student
{
int age;
float percntg;
};

struct student s1;

int a=25;
float p=88.99;
student assign(a,p)
{
student s2;
s2.age=a;
s2.percntg=p;
return s2;

}

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More C++ General Interview Questions

What is vector string in c++?

0 Answers  


What you mean by early binding and late binding? How it is related to dynamic binding?

1 Answers  


What does new in c++ do?

0 Answers  


Give 2 examples of a code optimization?

4 Answers  


Explain the volatile and mutable keywords.

0 Answers  


How one would use switch in a program?

0 Answers  


What is the difference between "calloc" and "malloc"?

9 Answers   ADP,


What is a null object in c++?

0 Answers  


Does dev c++ support c++ 11?

0 Answers  


total amount of milk produced each morning and then calculates and outputs the number of cartons needed for this milk , the cost of producing the milk and the profit from producing this milk.

0 Answers  


Which of the following is evaluated first: a) && b) || c) !

0 Answers  


Explain one-definition rule (odr).

0 Answers  


Categories