// A function whose return value is a struct
#include <iostream>
using namespace std;

struct fruit {
  string origin;
  double weight;
  int price;
};

fruit setProperties(string s, double w, double p){
   fruit f;
   f.origin = s;
   f.weight = w;
   f.price  = p;
   return f;
}

int main(){
  fruit x = setProperties("Asia",2.45, 31);
  cout << x.origin << endl;
  cout << x.weight << endl;
  cout << x.price  << endl;
}

