#include <iostream>
#include <string>
#include <clocale>
using namespace std;
int main()
{
setlocale(LC_ALL, "RUS");
int numeric_array_marks[8] = { 3, 4, 4, 5, 2, 3, 3, 4 };
string text_array_marks[8];
for (int i = 0; i < 8; i++)
switch (numeric_array_marks[i])
case 2:
text_array_marks[i] = "неудовлетворительно";
break;
case 3:
text_array_marks[i] = "удовлетворительно";
case 4:
text_array_marks[i] = "хорошо";
case 5:
text_array_marks[i] = "отлично";
}
cout << text_array_marks[i] << endl;
#include <iostream>
#include <string>
#include <clocale>
using namespace std;
int main()
{
setlocale(LC_ALL, "RUS");
int numeric_array_marks[8] = { 3, 4, 4, 5, 2, 3, 3, 4 };
string text_array_marks[8];
for (int i = 0; i < 8; i++)
switch (numeric_array_marks[i])
{
case 2:
text_array_marks[i] = "неудовлетворительно";
break;
case 3:
text_array_marks[i] = "удовлетворительно";
break;
case 4:
text_array_marks[i] = "хорошо";
break;
case 5:
text_array_marks[i] = "отлично";
break;
}
for (int i = 0; i < 8; i++)
cout << text_array_marks[i] << endl;
}