STL,vectors and strings

In the seminar of 2d arrays and strings there was a homework question to find the which row or column has max sum.
Can anyone provide the solution beside the brute force…