// This program reads in data from "grid_data.txt" to a 10 X 20 array. The user is prompted for indices into // the array and the program will display the contents of the cells neighboring the input cell indices. #include #include using namespace std; int main() { int i, j, row_select=0, col_select=0; const int row = 10, col = 20; char grid[row][col]; ifstream infile; infile.open("input.txt"); if(!infile) { cout << "Could not open input file, please check."<> grid[i][j]; cout<<" "<> row_select >> col_select; // check to see if the entered coordinates are out of range - enter again if so while ((row_select <0)||(row_select >= row)||(col_select < 0)||(col_select>=col)) { cout << "One or more of your indices is out of range, try again"<>row_select>>col_select; } cout << endl << "The neighbors of grid["<=0)&&(i=0)&&(j