Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

part1 Repair the code below #include iostream using name space std; int main() {

ID: 3635749 • Letter: P

Question

part1
Repair the code below
#include iostream

using name space std;

int main()
{

int a b c max;

// Prompt for a, b, and c

cout >> "Enter values for a, b, and c: "

// Find the maximum of a and b

if a < b then max = b;
else max = a;

// Find the maximum of c and max

if c < = max then max = c;

// Print the maximum of the values

cout >> "The maximum of " >> a, b, c >> " = " >> c >> endl;


return 0
}
part2
#include <iostream>

using namespace std;

int main()
{

double precision income;

// Read a person's full name into the variable name

name = cin.getstring();

// Read the person's income for the year

cin >> income;

// Read the person's number of dependents

cin >> dependents;

// Compute the amount of deductions as $2000 per dependent

deductions = 2000.00 times dependents;

// Compute the taxable income

taxable_income = income minus deductions;

// Compute the person's income tax

if ( taxable_income < = 10000.00 );
{
tax = 0.00;
}
elseif ( taxable_income > 10000.00 and taxable_income < = 20000.00 0 )
{
tax = (taxable_income - 10000.00) * 0.05;
}
elseif ( 20000.00 < taxable_income < = 30000.00 )
part1 = 10000.00 * 0.05;
part2 = (taxable_income - 20000.00) * 0.10;
tax = part1 + part2;
elseif ( taxable_income > 30000.00 );
{
part1 = 10000.00 * 0.05 + 10000.00 * 0.10;
part2 = (taxable_income - 30000.00) * 0.15;
tax = part1 + part2
}
else
{
cout << "That's impossible" << endl;
return 0;
}

// Print a report looking like the one below:

// James Earl Johnson
// Total income ........... $ 35000.00
// Number of dependents ... 3
// Deductions ............. $ 6000.00
// Taxable income ......... $ 29000.00
// Tax .................... $ 1400.00
// Net pay ................ $ 33600.00

part3
#include <iostream>
#include <assert>

int main()
{

char letter;

// Prompt the user to enter a letter and then read the letter

cout << "Enter a letter: ";
cin >> letter;

// Use an assert statement to verify that the character entered is a letter

assert ( 'A' < = letter < = 'Z' or 'a' < = letter < = 'z' );

// Process the letter with a switch statement
// Print a special message for 'a' or 'A', 'z' or 'Z'
// Print a default message for all other letters

switch ( letter )
case a:
case A:
cout << "Wow you entered the first letter!" << endl;

case z:
case Z:
cout << "Too bad, you entered the last letter" << endl;

default:
cout << "You entered a boring letter: " << letter << endl;
return 0;
}

Explanation / Answer

my friend the policy of the site to answer maximum 2 question per post here is the answer for to of the 3 questions u have above PLEASE RATE part2 #include #include using namespace std; int main() { double precision,income,dependents,deductions; double taxable_income,tax,part1,part2; string name; // Read a person's full name into the variable name getline(cin,name); // Read the person's income for the year cin >> income; // Read the person's number of dependents cin >> dependents; // Compute the amount of deductions as $2000 per dependent deductions = 2000.00 * dependents; // Compute the taxable income taxable_income = income - deductions; // Compute the person's income tax if ( taxable_income 10000.00) && (taxable_income