/* DOUBLE ALTERNATIVE The if-else if statement A bicycle salesperson was offered a choice of wage plans: |a. A straight salary of 5000 per week. b. 50.00 per hour for 40 hours plus 107. commission from sales. c. A 20% commission on sales with no other salary. Draw the flowchart and write or code the C program that Would take the salesperson' s weekly sales. Output the 3 wage plans as well as anmouncing the best paying-plan. */

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

Using Dev C++ or Turbo C++, please help me code this problem. Also, please use the coding style in image "ex2".

Thank you in advance.

= File Edit Search Run Compile Debug Pro ject Options
Window Help
1=[*]¬
WAGE.C
/* DOUBLE ALTERNATIVE
The if-else if statement
A bicycle salesperson was offered a choice of wage plans:
a. A straight salary of 5000 per week.
b. 50.00 per hour for 40 hours plus 10% commission from sales.
c. A 20% commission on sales with no other salary.
Draw the flowchart and write or code the C program that would take the
sa lesperson's weekly sales. Output the 3 wage plans as wel1 as announcing
the best paying-plan.
*/
21:1
F1 Help F2 Save F3 0pen Alt-F9 Compile F9 Make
F10 Menu
Transcribed Image Text:= File Edit Search Run Compile Debug Pro ject Options Window Help 1=[*]¬ WAGE.C /* DOUBLE ALTERNATIVE The if-else if statement A bicycle salesperson was offered a choice of wage plans: a. A straight salary of 5000 per week. b. 50.00 per hour for 40 hours plus 10% commission from sales. c. A 20% commission on sales with no other salary. Draw the flowchart and write or code the C program that would take the sa lesperson's weekly sales. Output the 3 wage plans as wel1 as announcing the best paying-plan. */ 21:1 F1 Help F2 Save F3 0pen Alt-F9 Compile F9 Make F10 Menu
EXAMP2.C
-2=[↑]케
#include<stdio.h>
ma in()
int a,b,p,s;
clrscr();
pr intf ("Enter the value of a:");
printf ("Enter the value of b:");
scanf ("zd",&a );
scanf ("zd",&b);
if (a>b)
{
p=a*b;
printf ("zd * zd = %d",a,b,p)
else
{
s=a+b;
printf ("zd + %d = Zd",a,b,s);
getch();
Transcribed Image Text:EXAMP2.C -2=[↑]케 #include<stdio.h> ma in() int a,b,p,s; clrscr(); pr intf ("Enter the value of a:"); printf ("Enter the value of b:"); scanf ("zd",&a ); scanf ("zd",&b); if (a>b) { p=a*b; printf ("zd * zd = %d",a,b,p) else { s=a+b; printf ("zd + %d = Zd",a,b,s); getch();
Expert Solution
steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY