-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstadium.h
75 lines (66 loc) · 1.62 KB
/
stadium.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<<<<<<< HEAD
#include <string>
#include <vector>
using namespace std;
#ifndef STADIUM_H
#define STADIUM_H
struct Stadium
{
string name;
vector<string> teams;
string address;
string box_office_number;
string date_opened;
string seating_capacity;
string league;
Stadium() {}
Stadium(string name,
string team,
string address,
string box_office_number,
string date_opened,
string seating_capacity,
string league)
{
this->name = name;
this->teams.push_back(team);
this->address = address;
this->box_office_number = box_office_number;
this->date_opened = date_opened;
this->seating_capacity = seating_capacity;
this->league = league;
}
void add_team(string team)
{
this->teams.push_back(team);
}
void remove_team(int index)
{
this->teams.erase(this->teams.begin() + index);
}
};
#endif // STADIUM_H
=======
#ifndef STADIUM_H_
#define STADIUM_H
#include <iostream>
#include <string>
using namespace std;
class Stadium
{
private:
string name;
string team;
string league;
public:
explicit Stadium(string name): name(name), team(""), league("") {}
Stadium(): name(""), team(""), league("") {}
string get_name()const;
string get_team()const;
string get_league()const;
void update_name(string new_name);
void update_team(string new_team);
void update_league(string new_league);
};
#endif // STADIUM_H_
>>>>>>> 9bd10836bcb8c4a3e3e776121d1c4ea862696841