Hello there, please solve this c++ mindtab 10-13 exrecise please? I need the correct code and the screen shoot of code,thanks

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Hello there, please solve this c++ mindtab 10-13 exrecise please? I need the correct code and the screen shoot of code,thanks!!

Instructions

In this exercise, you will design the class memberType.

  1. Each object of memberType can hold the name of a person, member ID, number of books bought, and amount spent.
  2. Include the member functions to perform the various operations on the objects of memberType—for example, modify, set, and show a person’s name. Similarly, up-date, modify, and show the number of books bought and the amount spent.
  3. Add the appropriate constructors.
  4. Write the definitions of the member functions of memberType.
  5. Write a program to test various operations of your class memberType.
main.cpp
14
2 18
3 John Williams
40
50
6 20
7 Lisa Berry
82
9 35.50
10 30
11 Ron Brown
12 10
13 255.68
14 40
15 Jessey Smith
16 0
17 0
18
memberType.h
memberData.txt
memberTypelmp.c...
+ >_
Transcribed Image Text:main.cpp 14 2 18 3 John Williams 40 50 6 20 7 Lisa Berry 82 9 35.50 10 30 11 Ron Brown 12 10 13 255.68 14 40 15 Jessey Smith 16 0 17 0 18 memberType.h memberData.txt memberTypelmp.c... + >_
5. Write a program to test various operations of your
class memberType.
main.cpp
1 #include <iostream>
2 #include <string>
3 #include <fstream>
4 #include "memberType.h"
5
6 using namespace std;
7
8 int main()
12
13
memberType.h
10 // Write your main here.
11
return 0;
memberData.txt
memberTypelmp.c... +
Transcribed Image Text:5. Write a program to test various operations of your class memberType. main.cpp 1 #include <iostream> 2 #include <string> 3 #include <fstream> 4 #include "memberType.h" 5 6 using namespace std; 7 8 int main() 12 13 memberType.h 10 // Write your main here. 11 return 0; memberData.txt memberTypelmp.c... +
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Follow-up Questions
Read through expert solutions to related follow-up questions below.
Follow-up Question

It is not working, still i got 0/100. Please help me

← → C
»
M Gmail ► YouTube
(2
?
chaltugele xb Answered: x
Q
AH
m
✓=
Programming Exercise 10-13
bl
C
CENGAGE MINDTAP
Maps Evangadi Networks
Tasks
Home Com X D2L 17-Operat X
ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064173&
The program can initialize
objects of type memberType
without error.
memberType 's isMemberID
indicates which member object
is assigned the provided ID.
memberType 's
getBooksPurchased returns
the number of books purchased.
memberType 's
get Total AmountSpent returns
the total amount spent.
Type here to search
Run checks
Je
Submit 0%
E
MindTap - X
main.cpp
MindTap - X
1 #include <iostream>
2 #include <string>
3 #include <fstream>
4 #include "memberType.h"
5
8 int main()
9 {
10
11
12
13
14
15
16
17
18
19
20
21
6 using namespace std;
7
Mailbox X
memberData.txt | memberType.h | memberTypel... +
O
int n; cin >> n;
while (n) {
Online Pay x
ios_base::sync_with_stdio(0);
cin.tie (0); cout.tie(0);
freopen("memberData.txt", "r", stdin);
string name, garbage;
int id, no;
double amount;
Paylocity X +
cin >> id;
getline (cin, garbage); //to take input from ne
getline (cin, name);
?
> Terminal
10
Before Updation
Ron Brown
10
255.68
After Updation
John Doe
5
10
Before Updation
Jessey Smith
0
0
After Updation
John Doe
5
10
Q Search this course
sandbox $
52°F Mostly clear
* ■
X +
0
X
9:30 AM
11/2/2022
с
X
:
?
A-Z
(((
B
Transcribed Image Text:← → C » M Gmail ► YouTube (2 ? chaltugele xb Answered: x Q AH m ✓= Programming Exercise 10-13 bl C CENGAGE MINDTAP Maps Evangadi Networks Tasks Home Com X D2L 17-Operat X ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064173& The program can initialize objects of type memberType without error. memberType 's isMemberID indicates which member object is assigned the provided ID. memberType 's getBooksPurchased returns the number of books purchased. memberType 's get Total AmountSpent returns the total amount spent. Type here to search Run checks Je Submit 0% E MindTap - X main.cpp MindTap - X 1 #include <iostream> 2 #include <string> 3 #include <fstream> 4 #include "memberType.h" 5 8 int main() 9 { 10 11 12 13 14 15 16 17 18 19 20 21 6 using namespace std; 7 Mailbox X memberData.txt | memberType.h | memberTypel... + O int n; cin >> n; while (n) { Online Pay x ios_base::sync_with_stdio(0); cin.tie (0); cout.tie(0); freopen("memberData.txt", "r", stdin); string name, garbage; int id, no; double amount; Paylocity X + cin >> id; getline (cin, garbage); //to take input from ne getline (cin, name); ? > Terminal 10 Before Updation Ron Brown 10 255.68 After Updation John Doe 5 10 Before Updation Jessey Smith 0 0 After Updation John Doe 5 10 Q Search this course sandbox $ 52°F Mostly clear * ■ X + 0 X 9:30 AM 11/2/2022 с X : ? A-Z ((( B
← → C
»
M Gmail ► YouTube
明
?
chaltugele xb Answered: x
Q
AH
Y=
....
Programming Exercise 10-13
C
CENGAGE MINDTAP
Maps Evangadi Networks
Tasks
ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064173&
Home Com X D2L 17-Operat X
Awww
MindTap - X
In file included from /root/sandbox6939252b/nt-test-c1bc59bc.cpp:2:0:
/root/sandbox6939252b/memberTypeImp.cpp:4:5: note: candidate: memberType: :memb
memberType: :memberType(string name, int member_id, int n, double amount)
class memberType
~~~
Type here to search
MindTap- x
/root/sandbox6939252b/memberTypeImp.cpp:4:5: note: candidate expects 4 argum
In file included from /root/sandbox6939252b/memberTypeImp.cpp:1:0,
from /root/sandbox6939252b/nt-test-c1bc59bc.cpp:2:
/root/sandbox6939252b/memberType.h:5:7: note: candidate: memberType: :member Typ
Mailbox X
/root/sandbox6939252b/memberType.h:5:7: note: candidate expects 1 argument, (
/root/sandbox6939252b/memberType.h:5:7: note: candidate: memberType: :memberType
/root/sandbox6939252b/memberType.h:5:7: note: candidate expects 1 argument, (
/root/sandbox6939252b/nt-test-c1bc59bc.cpp:5:16: error: no matching function f
memberType member2;
Ne ne m
In file included from /root/sandbox6939252b/nt-test-c1bc59bc.cpp:2:0:
/root/sandbox6939252b/memberTypeImp.cpp:4:5: note: candidate: memberType: :membe
OXE
Run checks
Online Pay x
Submit 0%
main.c... memb... | memb... |
1 #include <iostream>
2 #include <string>
3 #include <fstream>
4 #include "memberType.h"
5
6 using namespace std;
7
8 int main()
9 {
10
◆ Paylocity X +
11
12
13
14
15
16
17
18
19
(0);
?
me +
"r", stdin);
int n; cin >>n;
while (n--) {
Q Search this course
5
ios_base::sync_with_st 10
string name, garba
int id, no;
double amount;
cin >> id;
52°F Mostly clear
>_ Termin x
10
cin.tie (0); cout.tie( Before Updation
freopen("memberData.tx Jessey Smith
* ■
Before Updation
Ron Brown
10
255.68
After Updation
John Doe
0
0
5
10
After Updation
John Doe
0
X
+
sandbox $
GJ
9:34 AM
11/2/2022
с
X
:
?
A-Z
B
Transcribed Image Text:← → C » M Gmail ► YouTube 明 ? chaltugele xb Answered: x Q AH Y= .... Programming Exercise 10-13 C CENGAGE MINDTAP Maps Evangadi Networks Tasks ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064173& Home Com X D2L 17-Operat X Awww MindTap - X In file included from /root/sandbox6939252b/nt-test-c1bc59bc.cpp:2:0: /root/sandbox6939252b/memberTypeImp.cpp:4:5: note: candidate: memberType: :memb memberType: :memberType(string name, int member_id, int n, double amount) class memberType ~~~ Type here to search MindTap- x /root/sandbox6939252b/memberTypeImp.cpp:4:5: note: candidate expects 4 argum In file included from /root/sandbox6939252b/memberTypeImp.cpp:1:0, from /root/sandbox6939252b/nt-test-c1bc59bc.cpp:2: /root/sandbox6939252b/memberType.h:5:7: note: candidate: memberType: :member Typ Mailbox X /root/sandbox6939252b/memberType.h:5:7: note: candidate expects 1 argument, ( /root/sandbox6939252b/memberType.h:5:7: note: candidate: memberType: :memberType /root/sandbox6939252b/memberType.h:5:7: note: candidate expects 1 argument, ( /root/sandbox6939252b/nt-test-c1bc59bc.cpp:5:16: error: no matching function f memberType member2; Ne ne m In file included from /root/sandbox6939252b/nt-test-c1bc59bc.cpp:2:0: /root/sandbox6939252b/memberTypeImp.cpp:4:5: note: candidate: memberType: :membe OXE Run checks Online Pay x Submit 0% main.c... memb... | memb... | 1 #include <iostream> 2 #include <string> 3 #include <fstream> 4 #include "memberType.h" 5 6 using namespace std; 7 8 int main() 9 { 10 ◆ Paylocity X + 11 12 13 14 15 16 17 18 19 (0); ? me + "r", stdin); int n; cin >>n; while (n--) { Q Search this course 5 ios_base::sync_with_st 10 string name, garba int id, no; double amount; cin >> id; 52°F Mostly clear >_ Termin x 10 cin.tie (0); cout.tie( Before Updation freopen("memberData.tx Jessey Smith * ■ Before Updation Ron Brown 10 255.68 After Updation John Doe 0 0 5 10 After Updation John Doe 0 X + sandbox $ GJ 9:34 AM 11/2/2022 с X : ? A-Z B
Solution
Bartleby Expert
SEE SOLUTION
Follow-up Question

Hello I did this code but it give me 0/100

If you attached the code screen shoot , it is easy to understand.

thanks!!

 

Home Communit X D21 Workshop4 - CSC x | CSC 1060 FA22 - X
← → C
M Gmail ► YouTube
»
明
?
Q
AH
m
✓=
Programming Exercise 10-13
Tabl
MindTap - Cenga × b Success Confirma X chaltugeletu@yal x b Answered: Hello x +
ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064173&
C
CENGAGE MINDTAP
Maps Evangadi Networks
Tasks
U
The program can initialize objects of type
memberType without error.
memberType 's isMember ID indicates
which member object is assigned the
provided ID.
memberType 's getBooks Purchased
returns the number of books purchased.
memberType 's get Total Amount Spent
returns the total amount spent.
memberType 's purchaseBook returns
the total amount spent plus the amount of
the new purchase.
Type here to search
Run checks
2004
JO
E
Je
Je
Je
Submit 0%
main.cpp
10
11
12 public:
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
double amount_spent;
O
amount) {
memberData... memberType... memberType... | +
}
//constructor
0
memberType(string name, int member_id, int n,
0
}
this->name = name;
this -> member_id = member_id;
this->no_of_books_bought = n;
this amount_spent = amount;
->
void setName(string name) {
this->name = name;
void showName() {
cout << this -> name << endl;
}
void setNoOfBooksBought (int no) {
>_ Terminal
?
sandbox $ ./a.out
Before Updation
John Williams
After Updation
John Doe
5
10
Q Search this course
Before Updation
Lisa Berry
2
35.5
After Updation
John Doe
5
10
Before Updation
Ron Brown
69°F Sunny
* ■
X +
0
X
3:41 PM
11/1/2022
с
X
:
?
A-Z
B
Transcribed Image Text:Home Communit X D21 Workshop4 - CSC x | CSC 1060 FA22 - X ← → C M Gmail ► YouTube » 明 ? Q AH m ✓= Programming Exercise 10-13 Tabl MindTap - Cenga × b Success Confirma X chaltugeletu@yal x b Answered: Hello x + ng.cengage.com/static/nb/ui/evo/index.html?deploymentid=5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064173& C CENGAGE MINDTAP Maps Evangadi Networks Tasks U The program can initialize objects of type memberType without error. memberType 's isMember ID indicates which member object is assigned the provided ID. memberType 's getBooks Purchased returns the number of books purchased. memberType 's get Total Amount Spent returns the total amount spent. memberType 's purchaseBook returns the total amount spent plus the amount of the new purchase. Type here to search Run checks 2004 JO E Je Je Je Submit 0% main.cpp 10 11 12 public: 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 double amount_spent; O amount) { memberData... memberType... memberType... | + } //constructor 0 memberType(string name, int member_id, int n, 0 } this->name = name; this -> member_id = member_id; this->no_of_books_bought = n; this amount_spent = amount; -> void setName(string name) { this->name = name; void showName() { cout << this -> name << endl; } void setNoOfBooksBought (int no) { >_ Terminal ? sandbox $ ./a.out Before Updation John Williams After Updation John Doe 5 10 Q Search this course Before Updation Lisa Berry 2 35.5 After Updation John Doe 5 10 Before Updation Ron Brown 69°F Sunny * ■ X + 0 X 3:41 PM 11/1/2022 с X : ? A-Z B
Home Communit X D21 Workshop4 - CSC x | CSC 1060 FA22 - X
← → C
M Gmail ► YouTube
»
明
?
Q
AH
0
✓=
Programming Exercise 10-13
Tabl
MindTap - Cenga × b Success Confirma X chaltugeletu@yal x b Answered: Hello x +
ng.cengage.com/static/nb/ui/evo/index.html?deploymentld-5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064...
&
Maps Evangadi Networks
CENGAGE MINDTAP
Tasks
Bulla Output
/root/sandbox173aa336/nt-test-45edc7cf.c
/root/sandbox173aa336/nt-test-45edc7cf.c
memberType member1;
A me me me me
/root/sandbox173aa336/nt-test-45edc7cf.c
memberType member2;
/root/sandbox173aa336/nt-test-45edc7cf.c
member2.setMemberInfo("MID1234", "
N
meme me me me
/root/sandbox173aa336/nt-test-45edc7cf.c
member2.setMemberInfo("MID1234", "
memmem
make[2]: *** [CMakeFiles/runTests.dir/nt
make[1]: *** [CMakeFiles/runTests.dir/al
make: *** [all] Error 2
Type here to search
Run checks
200 UE
Submit 0%
E
X
main.cpp
memberData... memberType... memberType... | +
double amount_spent;
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
10
11
12 public:
13
//constructor
14 memberType(string name, int member_id, int n,
0
amount) {
O
}
this->name = name;
this -> member_id = member_id;
this->no_of_books_bought = n;
this amount_spent = amount;
}
->
void setName(string name) {
this->name = name;
void showName() {
cout << this -> name << endl;
}
void setNoOfBooksBought (int no) {
>_ Terminal
?
0
sandbox $ ./a.out
Before Updation
John Williams
After Updation
John Doe
5
10
Q Search this course
Before Updation
Lisa Berry
2
35.5
After Updation
John Doe
5
10
Before Updation
Ron Brown
69°F Sunny
X +
口
0
X
3:39 PM
11/1/2022
X
С :
?
A-Z
B
Transcribed Image Text:Home Communit X D21 Workshop4 - CSC x | CSC 1060 FA22 - X ← → C M Gmail ► YouTube » 明 ? Q AH 0 ✓= Programming Exercise 10-13 Tabl MindTap - Cenga × b Success Confirma X chaltugeletu@yal x b Answered: Hello x + ng.cengage.com/static/nb/ui/evo/index.html?deploymentld-5785052505173588133070619748&eISBN=9781337631952&id=1558664741&snapshotld=3064... & Maps Evangadi Networks CENGAGE MINDTAP Tasks Bulla Output /root/sandbox173aa336/nt-test-45edc7cf.c /root/sandbox173aa336/nt-test-45edc7cf.c memberType member1; A me me me me /root/sandbox173aa336/nt-test-45edc7cf.c memberType member2; /root/sandbox173aa336/nt-test-45edc7cf.c member2.setMemberInfo("MID1234", " N meme me me me /root/sandbox173aa336/nt-test-45edc7cf.c member2.setMemberInfo("MID1234", " memmem make[2]: *** [CMakeFiles/runTests.dir/nt make[1]: *** [CMakeFiles/runTests.dir/al make: *** [all] Error 2 Type here to search Run checks 200 UE Submit 0% E X main.cpp memberData... memberType... memberType... | + double amount_spent; 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 10 11 12 public: 13 //constructor 14 memberType(string name, int member_id, int n, 0 amount) { O } this->name = name; this -> member_id = member_id; this->no_of_books_bought = n; this amount_spent = amount; } -> void setName(string name) { this->name = name; void showName() { cout << this -> name << endl; } void setNoOfBooksBought (int no) { >_ Terminal ? 0 sandbox $ ./a.out Before Updation John Williams After Updation John Doe 5 10 Q Search this course Before Updation Lisa Berry 2 35.5 After Updation John Doe 5 10 Before Updation Ron Brown 69°F Sunny X + 口 0 X 3:39 PM 11/1/2022 X С : ? A-Z B
Solution
Bartleby Expert
SEE SOLUTION
Knowledge Booster
Structured English
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education