I'm writing a program that get integers from a text file and ouputs it to another but when i ouput it, the integers are in vertical form:
78796
117894
109974
98204
101252
114826
32120
49940
32112
102058
How do i get it to be like this:
82848 101120 97206 115690 111120 110904
32644 78796 117894 109974 98204 101252
114826 32120 49940 32112 102058 111850
After 5 intgers it just to a new line.
1 2 3 4 5 6 7 8 9 10
while( input >> x )
{
if(EvenTest(x))
{
output << x << endl; // it outputs vertically but without the endl its horizontal.
}
}