Array Assignment
Create a plain text file with a sequence of 5 numbers separated by spaces. In your program, create an integer array of size 5, open the text file, and then assign the numbers within the file to each index in the array. Print the values in the array.
Once the values are assigned to the array, change the values within the array and overwrite the text file with the new values. Check the text file to see if the values have been overwritten.
- Previous
- Next