Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <string>
- #include <cstdlib>
- #include <ctime>
- using namespace std;
- class player
- {
- public:
- string name;
- int Accuracy;
- int Bulls_Hit;
- int DartsThrown;
- //functions
- void PrintAll()
- {
- cout << name << endl;
- cout << Accuracy << endl;
- cout << Bulls_Hit << endl;
- cout << DartsThrown << endl;
- }
- void Game()
- };
- int main()
- {
- player Joe;
- Joe.name = "Joe";
- Joe.Accuracy = 71;
- Joe.Bulls_Hit = 0;
- Joe.DartsThrown = 0;
- player Sid;
- Sid.name = "Sid";
- Sid.Accuracy = 73;
- Sid.Bulls_Hit = 0;
- Sid.DartsThrown = 0;
- Joe.PrintAll();
- Sid.PrintAll();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement