After that, answer the followingquestion:
Are all three parameters of the functionprocessDisc(…) needed in this new form of the program?
If yes, justify why (in words).
If no, eliminate the one(s) that is/are not necessary and make allchanges such that the program compiles correctly.
#include <iostream>
#include <string>
using namespace std;
/*
Input:name, unit price, and discount
percentage for a number of products
Output: the discounted price or message
*/
float processDisc(string,float,int);//now the fc returns afloat(discount)
int main()
{
string nameP;
float unitPr,discPr;
int perDisc;
char cont;
cont = ‘Y’;
while (cont == ‘Y’)
{
cout << “Name of product: “;
cin >> nameP;
cout << “Input unit price for ” << nameP << “:”;
cin >> unitPr;
cout << “Input the discount percentage for ”
PayPal Gateway not configured
PayPal Gateway not configured