In the code below i can'f figure out how to get the numbers from my inFile that will be reversed then put into my outFile. I left part of the code unfinished. not sure what I am supposed to put in between >> >>. pretty lost on this one. Im new at this so go easy. Thanks
#include <iostream>
#include <string>
#include <fstream>
using namespace std;
std::string word[5];
int main ()
{
//Declaring Variables
ifstream inFile;
ifstream inFile1;
ofstream outFile;
int item[5]; // An array item of 5 components
int counter;
int num, num1, num2, num3, num4;
inFile.open("numbers.txt");
inFile1.open("words.txt");
outFile.open("numberout.txt");
for (counter = 0; counter < 5; counter++)
{
inFile >> num >> num1 >> num2 >> num3 >> num4;
}
for (counter = 5; counter >= 0; counter--)
{
// unfinished code
outFile << << endl;
}