title: Error no match for 'operator=' (operand types are 'Person' and 'Person*')
body: <pre><code>In function 'int main()':
  41  14      [Error] no match for 'operator=' (operand types are 'Person' and 'Person*')
  41  14      [Note] candidate is:
  8   8       [Note] Person&amp; Person::operator=(const Person&amp;)
  8   8       [Note] no known conversion for argument 1 from 'Person*' to 'const Person&amp;'
  28          recipe for target 'main112.o' failed
  </code></pre>
  
  <p>Homework:</p>
  
  <p>Write a program for processing passenger information. Information includes:
  1) Full name of the passenger.
  2) Flight number.
  3) Luggage weight
  The program should allow the user to:
  1) Read data from the keyboard and display it.
  2) Calculate the number of passengers with the weight of baggage which is more than 10 kg</p>
  
  <pre><code>#include &lt;string&gt;
  #include &lt;iostream&gt;
  #include &lt;windows.h&gt;
  #include &lt;stdlib.h&gt;
  
  using namespace std;
  
  struct Person
  {
      string name;
      string race;
      int weight;
  
      void write();
      void show();
      void check();
  };
  
  void Person::show()
  {
      cout&lt;&lt;"ÔÈÎ: "&lt;&lt;name&lt;&lt;endl;
      cout&lt;&lt;"Íîìåð ðåéñà: "&lt;&lt;race&lt;&lt;endl;
      cout&lt;&lt;"Âåñ áàãàæà: "&lt;&lt;weight&lt;&lt;endl;
  }
  
  void Person::write()
  {
      cout&lt;&lt;"Ââåäèòå ÔÈÎ: ";
      getline(cin,name);
      cout&lt;&lt;"Ââåäèòå íîìåð ðåéñà: ";
      getline(cin,race);
      cout&lt;&lt;"Ââåäèòå âåñ áàãàæà: ";
      cin&gt;&gt;weight;
  }
  
  int main()
  {
      Person* persons=new Person[4];
      for (int i = 0; i &lt; 4; i++)
      {
          persons[i] = new Person();
          persons[i].write();
      }
      for (int i = 0; i &lt; 4; i++)
      {
          persons[i].show();
      }
      cout&lt;&lt;"Ñ áàãàæîì áîëüøå 10 êã: ";//&lt;&lt;counter&lt;&lt;" ÷åëîâåê"&lt;&lt;endl;
  
      return 0;
  }
  </code></pre>