Answer to Question #312534 in C++ for Raian

Question #312534

Mr. Tunan needs a directory that contains the following information.

(a) Name of a person

(b) Address

(c) Telephone Number

(d) Mobile Number

(e) Head of the family

He also needs a functionality to search the information of any person. Now develop a solution

using C++ for Tunan where you need to use a constructor to insert the information and a friend

function to show the output.


1
Expert's answer
2022-03-17T08:55:31-0400

Here is program:

class Person
{
public:
	Person(string name,string address,string phonenumber,string mobilenumber,string head)
	{
		this->name = name;
		this->address = address;
		this->phonenumber = phonenumber;
		this->mobilenumber = mobilenumber;
		this->head = head;
	}
private:
	string name;
	string address;
	string phonenumber;
	string mobilenumber;
	string head;
};

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