Computers and Technology

Write a Twitter class that sets the Twitter user first (who is to be followed) and lets the client add up to 5 followers, which will be stored in an array with a capacity of 5. These users/followers could be in the form of string or Profile. (Note that the followers are not stored as users, but as strings or Profiles).
At any time, your main program should be able to remove any user, x from following another user, y (i. e., x is no longer in the array of followers of y).
You are free to design your program as you wish as long as you fulfill the following requirements:
Twitter class should be declared as a template class (the template parameter defines how the followers are represented)
Twitter class includes a constructor that initializes the name of the user that is passed. The number of followers starts off at 0.
AddFollower function in Twitter class should be defined correctly. It takes as parameter an object of the template parameter.
RemoveFollower function in Twitter class should be defined correctly. It takes as parameter an object of the template parameter.
PrintFollowers function in Twitter class should be defined correctly. It displays the name of all the followers. (Remember: each follower is an object of the template parameter. As you will declare Profile struct which can be a template parameter, for the Profile struct, we must overload stream insertion << operator. Now, we can use cout << follower to display the follower).
Submitting a main program that tests the Twitter class as follows:
Twitter object
Twitter object
Whenever any change is made to a Twitter object (like a follower is added, a follower is removed), call PrintFollowers to display the followers of the Twitter object.

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 01:00, shayyy49
How can a broadcast station be received through cable and satellite systems?
Answers: 1
image
Computers and Technology, 24.06.2019 14:30, yeet74
Ahousehold consists of a married couple and their twin five-year old daughters. the couples children had no income and lived with their parents all of last year. how many exemptions can the couple claim on last years tax return or they file with the “ married filing jointly “ status? a. 4 b. 5 c. 3 d. 2
Answers: 1
image
Computers and Technology, 24.06.2019 22:00, ivethzurita0425
What is a number system, and what is the total number of digits used in this system called? a number system is a system that uses different (options: a) numbers b) symbols c) codes d) digits e) alphabets) to represent different numbers. the total number of digits used in a number system is known as its (options: 1) processor 2) converter 3) radix 4) least significant digit 5) most significant digit)
Answers: 1
image
Computers and Technology, 25.06.2019 00:00, ddatsman1730
One difference of input method between most desktop computers and most tablets is the memory the touch screen the speech recognition
Answers: 1
Do you know the correct answer?
Write a Twitter class that sets the Twitter user first (who is to be followed) and lets the client a...

Questions in other subjects: