Answered step by step
Verified Expert Solution
Question
1 Approved Answer
i have to modify previous code into the class objects OOP template right below this given code: #include #include #include #include #include using namespace std;
i have to modify previous code into the class objects OOP template right below this given code:
#include
struct FIELDS { string name; string value; };
const int cnt = 4;
// Prototypes void parse(string, FIELDS []); string param(string, FIELDS [], int);
//main begins int main() { FIELDS name_value_pairs [cnt];
string qs(getenv("QUERY_STRING")); cout << "Content-type:text/html ";
parse(qs, name_value_pairs);
string first = param("first", name_value_pairs, cnt); string last = param("last", name_value_pairs, cnt); string color = param("color", name_value_pairs, cnt); string witch = param("witch", name_value_pairs, cnt);
cout<<""; cout<<"