12345678910111213141516171819
#include<iostream> using namespace std; int main(){ int subject[2][3] = { {90,96,95}, {98,90,91} }; \\how to convert this using a loop: float ave1 = (subject[0][0] + subject[0][1] + subject[0][2]) / 3.0f; float ave2 = (subject[1][0] + subject[1][1] + subject[1][2]) / 3.0f; cout << ave1 << endl; cout << ave2 << endl; return 0; }