Add a new function to your project


Two parts to this project for c++.
part 1
• Add a new function to your project called: ReverseIt() 
• From the main function call ReverseIt(). 
• ReverseIt will create an array to hold 10 integers, open your input file, read each line, add the integer on 
each line into the array. Close the input file. 
• At this point, ReverseIt function has an array of 10 integers that it read from the file. 
• Now open an output file called ReverseArray.txt, and write the array elements into the file in reverse order. In other words, the last integer that you read from your StraightArray.txt will be the first integer in this ReverseArray.txt file 

and

part 2
• Add a new function to your project called: ReverseIt() 
• From the main function call ReverseIt(). 
• ReverseIt will open StraightStrings.txt as input file and open a ReverseStrings.txt file as output file. 
• It will read one line of the input file and put its string into a character array. 
• Then write the character array in reverse order into the output file: 
o Example: input string = "Hello World" Î output string to output file = "dlroW olleH" 
• Note: this is done one string at a time. You are not reading all the input file strings into an array, then processing them. You are reading one string from the input file, and then writing it to the output file 

Request for Solution File

Ask an Expert for Answer!!
C/C++ Programming: Add a new function to your project
Reference No:- TGS0116346

Expected delivery within 24 Hours