The following code does not compile. Find 12 legitimate errors Note: If there is a discrepancy with a variable between the function call and the function definition, that only counts as one error. You may mark the error as either location. For each error clearly identify in your response: The line number on which the error occurs What the error is (e.g. "missing semicolon at end of line") The type of error (compile, logic, runtime) please see attached image
The following code does not compile. Find 12 legitimate errors Note: If there is a discrepancy with a variable between the function call and the function definition, that only counts as one error. You may mark the error as either location. For each error clearly identify in your response: The line number on which the error occurs What the error is (e.g. "missing semicolon at end of line") The type of error (compile, logic, runtime) please see attached image
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
Related questions
Question
100%
The following code does not compile.
Find 12 legitimate errors
Note: If there is a discrepancy with a variable between the function call and the function definition, that only counts as one error. You may mark the error as either location.
For each error clearly identify in your response:
- The line number on which the error occurs
- What the error is (e.g. "missing semicolon at end of line")
- The type of error (compile, logic, runtime)
please see attached image
![HAHAHAHN
HN35∞ OHNMST ∞ H
1 #include <iostream>
2
3 using namespace std;
4
6
7
8
10 }
11
12
13
N N N N N N N N
14
15
16
17
18
19
20
wwwwwwww.
24
25
26
27
28
21
22 void printCheck (double rate, double hrs, int pay) {
cout << "EMPLOYEE PAYCHECK" << \n;
23
cout <<
cout << "Hours worked: " << hrs << endl;
"Pay rate: " << rate << endl;
cout << "Gross pay: << pay << endl;
return false;
597AWNPO
31
32
33
boolean getHoursRate (double &hrs, int rate, char bob) {
cout << "Please enter hours worked: ";
cin >> h;
cout << "Please enter weekly pay rate:
cin >> rate;
29
30 int main ():
34
35
36
double calculate PayCheck (double hours, double rate) {
int pay;
}
}
if (hrs >= 40)
pay hrs * rate / 2;
else;
11
37 ]
pay = 40 * rate + ((hrs 40) * rate * 1.5);
return rate;
double rate, hours, amount;
cout >> "=== Paycheck program ===\n\n";
getHoursRate (hours, rate);
amount = calculatePayCheck (hours, rate);
printCheck (hours, rate, amount);
return 0;](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F55cddd6a-12fb-4e1b-bd64-bee5ba717ee4%2F2e5ffd47-97a9-45e5-bada-37ab5e4d709c%2F0bn6rds_processed.png&w=3840&q=75)
Transcribed Image Text:HAHAHAHN
HN35∞ OHNMST ∞ H
1 #include <iostream>
2
3 using namespace std;
4
6
7
8
10 }
11
12
13
N N N N N N N N
14
15
16
17
18
19
20
wwwwwwww.
24
25
26
27
28
21
22 void printCheck (double rate, double hrs, int pay) {
cout << "EMPLOYEE PAYCHECK" << \n;
23
cout <<
cout << "Hours worked: " << hrs << endl;
"Pay rate: " << rate << endl;
cout << "Gross pay: << pay << endl;
return false;
597AWNPO
31
32
33
boolean getHoursRate (double &hrs, int rate, char bob) {
cout << "Please enter hours worked: ";
cin >> h;
cout << "Please enter weekly pay rate:
cin >> rate;
29
30 int main ():
34
35
36
double calculate PayCheck (double hours, double rate) {
int pay;
}
}
if (hrs >= 40)
pay hrs * rate / 2;
else;
11
37 ]
pay = 40 * rate + ((hrs 40) * rate * 1.5);
return rate;
double rate, hours, amount;
cout >> "=== Paycheck program ===\n\n";
getHoursRate (hours, rate);
amount = calculatePayCheck (hours, rate);
printCheck (hours, rate, amount);
return 0;
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 5 steps with 3 images

Knowledge Booster
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.Recommended textbooks for you

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)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

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)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON

Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning

Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education