#include <iostream>
#include <iomanip>
#include <fstream>
#include <string>

const int cand = 5;
const int regions = 4;

using namespace std;



int main()
{
    ifstream infile;
      string filename;
        int votes[cand][regions];
          int total_votes[cand];
            int k, vote_count, candidate, region, sum;

            votes[0][0] = 1;
            votes[1][0] = 2;
            votes[2][0] = 3;
            votes[3][0] = 4;
            votes[4][0] = 5;


            cout << "Enter input file name:  ";
            cin >> filename;
              infile.open(filename.c_str());
                if(!infile) {
                      cerr << "Error: Can't open file." << endl;
                          return 1;
                            }

infile >> candidate >> region >> vote_count;
cout << candidate << endl << region << endl << vote_count << endl;
while(infile)// && k < cand) { // if not eof and array has space for item
     {
//           votes[candidate][region] = vote_count;

              // ++k;         // next location in array, number of items in array
     infile >> candidate; // read next item
         infile >> region;
             infile >> vote_count;
               }
           
                
return 0;
}

