My first suggestion is that the prof wants a list of Record - rather than hardcoding in 19
, use a vector and fill it as you go.
vector<Record> records;
My second suggestion is to use a loop to process each month.
vector<string> months;
months.push_back("Jan");
months.push_back("Feb");
for (int i = 0; i < months.size(); ++i) {
string month = months[i];
ReadInMonthBudget(&records, month); // Then use a function to read in each month file.
}
Then you can work on collecting your stats:
for (int i = 0; i < months.size(); ++i) {
string month = months[i];
cout << "Min spender in month " << month << ": " << FindMinSpenderInMonth(records, month);
}
Using functions will make your code much easier to understand (and write), because it breaks the problem down into much smaller chunks that are easier to solve.
Start by getting it working, then improve on it. If this is a college level class, your professor may want you to come up with a better than O(n^2) solution.