Answer to Question #241326 in C++ for Epiiii

Question #241326
Create a Class parten wien data mentides

name

gender

and member functions to perform the following

operations:

a Accopt the details of an person

b. Display the details of an person
1
Expert's answer
2021-09-23T17:45:42-0400
class parten_wien {
  std::string name;
  std::string gender;
public:
  void accopt(std::string name, std::string gender) {
    this->name = name;
    this->gender = gender;
  }
  void display() {
    std::cout << "Name: " << this->name << std::endl;
    std::cout << "Gender: " << this->gender << std::endl;
  }
};

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
APPROVED BY CLIENTS