what should i do so that i can call the function computecoursework?

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

what should i do so that i can call the function computecoursework? 

C:\Users\huawei\Desktop\CPM213 LAB\example assignment.cpp - Dev-C++ 5.11
O X
File Edit Search View Project Execute Tools AStyle Window Help
TDM-GCC 4.9.2 64-bit Release
(globals)
Project Classes Debug
[*] ASSIGNMENT 1.cpp composition.cpp dynamic.cpp example assignment.cpp exp1.cpp exp6.cpp friendfunction.cpp Inheritance.cpp L2Q2.cpp L2Q3.cpp L2Q4.cpp L3Q1.cpp L3Q2.cpp L3Q3.cpp
void setcw(float cw)
{cw_mark=cw;
void printcwdetail()
35
36
}
37
38 E
cout <« "\n\t" < getname () <« "\t" « getmatric() « "\t" << test1 <« assignment1 <« cw_mark << endl;
}
coursework()
{test1=assignment1=0;}
"coursework ()
{test1=assignment1=0;
void computecw()
{cw_mark=test1*0.2+assignment1*0.3; }
};
int main()
39
40
41
42
43
44
45
46
47
48
49 E {
coursework cpt113;
string name;
int matric;
int test1;
int assignment1;
50
51
52
53
54
55
56
cout<<"name :";
getline(cin, name);
cout<<"\nmatric no :";
cin>>matric;
cout<<"\ntest 1 :";
cin>>test1;
cout « "\nAssignment 1 :";
cin>> assignment1;
cout « "\nCoursework mark: " k< cpt113.computecw();
57
58
59
60
61
62
63
64
66
88 Compiler (113)
Resources dh Compile Log V Debug a Find Results
Close
Line
Col
File
Message
65
32
C:\Users\huawei\Desktop\CPM213 LAB\example assign. [Error] no match for 'operator<<' (operand types are 'std:basic_ostream<char>' and 'void')
65
CAll-arel h.unil DarltanlCDA712I AD
ENetelsandid-ter are
Line: 65
Col: 35
Sel: 0
Lines: 66
Length: 1244
Insert
Done parsing in 0 seconds
7:50 PM
IMI
DEV
O Type here to search
85°F Light rain
a 4)) ENG
16/12/2021
Transcribed Image Text:C:\Users\huawei\Desktop\CPM213 LAB\example assignment.cpp - Dev-C++ 5.11 O X File Edit Search View Project Execute Tools AStyle Window Help TDM-GCC 4.9.2 64-bit Release (globals) Project Classes Debug [*] ASSIGNMENT 1.cpp composition.cpp dynamic.cpp example assignment.cpp exp1.cpp exp6.cpp friendfunction.cpp Inheritance.cpp L2Q2.cpp L2Q3.cpp L2Q4.cpp L3Q1.cpp L3Q2.cpp L3Q3.cpp void setcw(float cw) {cw_mark=cw; void printcwdetail() 35 36 } 37 38 E cout <« "\n\t" < getname () <« "\t" « getmatric() « "\t" << test1 <« assignment1 <« cw_mark << endl; } coursework() {test1=assignment1=0;} "coursework () {test1=assignment1=0; void computecw() {cw_mark=test1*0.2+assignment1*0.3; } }; int main() 39 40 41 42 43 44 45 46 47 48 49 E { coursework cpt113; string name; int matric; int test1; int assignment1; 50 51 52 53 54 55 56 cout<<"name :"; getline(cin, name); cout<<"\nmatric no :"; cin>>matric; cout<<"\ntest 1 :"; cin>>test1; cout « "\nAssignment 1 :"; cin>> assignment1; cout « "\nCoursework mark: " k< cpt113.computecw(); 57 58 59 60 61 62 63 64 66 88 Compiler (113) Resources dh Compile Log V Debug a Find Results Close Line Col File Message 65 32 C:\Users\huawei\Desktop\CPM213 LAB\example assign. [Error] no match for 'operator<<' (operand types are 'std:basic_ostream<char>' and 'void') 65 CAll-arel h.unil DarltanlCDA712I AD ENetelsandid-ter are Line: 65 Col: 35 Sel: 0 Lines: 66 Length: 1244 Insert Done parsing in 0 seconds 7:50 PM IMI DEV O Type here to search 85°F Light rain a 4)) ENG 16/12/2021
C:\Users\huawei\Desktop\CPM213 LAB\example assignment.cpp - Dev-C++ 5.11
O X
File Edit Search View Project Execute Tools AStyle Window Help
TDM-GCC 4.9.2 64-bit Release
(globals)
Project Classes Debug
[*] ASSIGNMENT 1.cpp composition.cpp dynamic.cpp example assignment.cpp exp1.cpp exp6.cpp friendfunction.cpp Inheritance.cpp L2Q2.cpp L2Q3.cpp L2Q4.cpp L3Q1.cpp L3Q2.cpp L3Q3.cpp
1
#include <iostream>
2
3
using namespace std;
4
class student
6E {
private:
string name;
int matric;
public:
string getname (){return name;}
int getmatric(){return matric;}
void setStudent(string n, int m){name=n; matric=m;}
student(){}
-student(){}
};
class coursework: public student
18 E {
7
8
9.
10
11
12
13
14
15
16
17
private:
int test1;
19
20
int assignment1;
float cw_mark;
public:
int getTest()
{return test1;}
intgetAssg()
{return assignment1;}
float getcw()
{return cw_mark;}
void setdetail(string n, int mat, int T1, int assg1)
{
setStudent (n, mat);
test1=T1;
assignment1=assg1:
21
22
23
24
25
26
27
28
29
30 E
31
32
33
88 Compiler (113)
Resources dh Compile Log V Debug a Find Results
Close
Line
Col
File
Message
65
32
C:\Users\huawei\Desktop\CPM213 LAB\example assign. [Error] no match for 'operator<<' (operand types are 'std:basic_ostream<char>' and 'void')
65
CAIlearel huuil Derltan CDA712I AD
INetel andidtar e
Line: 65
Col: 35
Sel: 0
Lines: 66
Length: 1244
Insert
Done parsing in 0 seconds
7:49 PM
IMI
DEV
O Type here to search
85°F Light rain
a 4)) ENG
16/12/2021
Transcribed Image Text:C:\Users\huawei\Desktop\CPM213 LAB\example assignment.cpp - Dev-C++ 5.11 O X File Edit Search View Project Execute Tools AStyle Window Help TDM-GCC 4.9.2 64-bit Release (globals) Project Classes Debug [*] ASSIGNMENT 1.cpp composition.cpp dynamic.cpp example assignment.cpp exp1.cpp exp6.cpp friendfunction.cpp Inheritance.cpp L2Q2.cpp L2Q3.cpp L2Q4.cpp L3Q1.cpp L3Q2.cpp L3Q3.cpp 1 #include <iostream> 2 3 using namespace std; 4 class student 6E { private: string name; int matric; public: string getname (){return name;} int getmatric(){return matric;} void setStudent(string n, int m){name=n; matric=m;} student(){} -student(){} }; class coursework: public student 18 E { 7 8 9. 10 11 12 13 14 15 16 17 private: int test1; 19 20 int assignment1; float cw_mark; public: int getTest() {return test1;} intgetAssg() {return assignment1;} float getcw() {return cw_mark;} void setdetail(string n, int mat, int T1, int assg1) { setStudent (n, mat); test1=T1; assignment1=assg1: 21 22 23 24 25 26 27 28 29 30 E 31 32 33 88 Compiler (113) Resources dh Compile Log V Debug a Find Results Close Line Col File Message 65 32 C:\Users\huawei\Desktop\CPM213 LAB\example assign. [Error] no match for 'operator<<' (operand types are 'std:basic_ostream<char>' and 'void') 65 CAIlearel huuil Derltan CDA712I AD INetel andidtar e Line: 65 Col: 35 Sel: 0 Lines: 66 Length: 1244 Insert Done parsing in 0 seconds 7:49 PM IMI DEV O Type here to search 85°F Light rain a 4)) ENG 16/12/2021
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Hiring Problem
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
  • SEE MORE 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