Using Visual studio C++
Arrays and Pointers 1 Task 1. If you have not already done so, install the Integrated Development Environment (IDE) on your computer. This will be Microsoft Visual Studio for the PC or Xcode for the MAC users. 2. Write, compile and run your first C++ program. This program outputs Hello world to the screen. Please refer to the instructions in Visual Studio Installation \& First Program posted on the Blackboard. 3. Write a program that initializes an array, and prints out the address and the contents of each element of an array using the pointer notation. You can initialize the array as follows: int arrN[10]={4,0,453,1029,44,67,111,887,4003,1002}; 4. The input file Cauchy.txt contains several lines of text. Write a program which opens and reads this file, one word at a time, and then prints this to the console. Utilize the fs canf() function. 5. (a) Write a function called Arraysparse, which determines if a 2D array is sparse or not. We define a 2D array to be sparse if its number of zero elements is at least twice as large as the number of non-zero elements. The argument to the function is a 2D array, which is an array of pointers to each row. (b) Declare and initialize an array of type int in main. Then utilize the above defined function to determine if the array is sparse or not sparse. As an example, you can choose an array of size 44. 1.1 AdditionalNotes - Visual Studio has known issues with the fscanf () function. Try using fscanf s () function instead. See the posted code ExampleIOReadVS.c. See also the posted folder Troubleshooting File I/O. - You may utilize the posted code Example2DArray. 2 Exercise Set Submission Please submit the exercise set in the provided link on the Blackboard. It should include the following: 1. The C++ source code, with one file per problem. 2. Screen shots which show each program executing. All the screen shots maybe in a single pdf or .jpg file