Write a C++ program that declares a two dimensional array of size5 called xy[5][5] and generates the values of its eleme
Posted: Tue May 24, 2022 7:59 am
Write a C++ program that declares a two dimensional array of size5 called xy[5][5] and generates the values of its elements using conditional statements as the following: • The main diagonal contains 0 in all its locations. • The upper triangle contains random numbers between x+2 and y+9 in all its locations, where x and y are the last two digits of your ID. • The lower triangle contains random numbers between 2 and 9 in all its locations. Display the resulted array on the screen and store it in a file called green.txt. Attach to your solution the following: • C++ code that can be checked (not a picture) .cpp file or just copy and paste your work here. • Screenshot of the results. Green.txt file.