Question: Question 1 a) Describe any two kinds of program errors? b) Explain why the use of functions is important in programming c) Write a C++

 Question 1 a) Describe any two kinds of program errors? b)

Question 1 a) Describe any two kinds of program errors? b) Explain why the use of functions is important in programming c) Write a C++ program that reads in three integers, determines and prints the [4 marks] [4 marks] largest and the smallest in the group [6 Marks] d) Consider the pseudocode below Use variables years OF TYPE INTEGER Use variables: sales, wage, loyaltyBonus OF TYPE REAL Use variable salesmanName OF TYPE STRING Begin DISPLAY "Please enter the name of a salesman ACCEPT salesmanName DISPLAY "Please enter sales for this period" ACCEPT sales DISPLAY "Please enter number of years he has spent in this Company" ACCEPT years wage : sales * 0.15 loyalty:Bonus : = wage * 0.1 IF yearS > 3 THEN wage : wage + loyalty-Bonus ENDIF DISPLAY salesmanNameearns " wage End [2 marks] i. What does the above pseudocode do? ii What would be displayed on the screen if the system user entered P3000 for sales, Paul Fisherman as salesman's name and 4 years for number of years spent? Write a C++ program to depict the above algorithm. 2 marks] 17 marks]

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!