Programming Final 100 points. In this final, you will be man…

Programming Final 100 points. In this final, you will be manipulating a grid. You may assume the user will enter correct input (unless noted). Read data that makes up a grid from a file The file must be named test.txt First two numbers in the file are the sizes of grid. The first number is the X size (so how many spots across), the second value is the Y size (how many spots down). After the sizes, the rest of the file is filled with data to fill in the grid. Example file: 3 4X Y YA B CD E FH F A Print out the contents in a grid. For the example file, the output should be X Y YA B CD E FH F A NOTE: Your array might be transposed once you print out the data. If you cannot figure it out quickly why that is, continue on and come back. A transposed print is worth a lot less than the rest of the exam. Repeatedly loop over a menu. Options in the menu: Update all the values in a row with a particular value The user enters in the row number and a value and all entries in that row are set to the value. Query a value if given the indexes. Here the user inputs an X and Y and you print out the value present at the spot. You must account for if the user does not enter a valid X or valid Y – send the user back to the menu if it is invalid. Print the grid. Print out whether a particular value is in the grid Here the user enters in a VALUE and you tell them if it exists in the grid. If anything else is entered then the program exits. Example run (using the previous example input file. NOTE: the test file can be different.) X Y Y A B C D E F H F A 1. Set all the values in a row an entered value2. Get the value at an index3. Print the grid4. Determine if in gridAny other input exits.Please enter an option: >> 1Which row?>> 1What value?>> 41. Set all the values in a row an entered value2. Get the value at an index3. Print the grid4. Determine if in gridAny other input exits.Please enter an option: >> 3X Y Y 4 4 4 D E F H F A 1. Set all the values in a row an entered value2. Get the value at an index3. Print the grid4. Determine if in gridAny other input exits.Please enter an option: >> 2Please enter in an x and y>> 0 1Value is: 41. Set all the values in a row an entered value2. Get the value at an index3. Print the grid4. Determine if in gridAny other input exits.Please enter an option: >> 4What value do you wish to check?>> AA exists1. Set all the values in a row an entered value2. Get the value at an index3. Print the grid4. Determine if in gridAny other input exits.Please enter an option: >> quit