I guess its that time of year everyones working on arrays and file outputs. So here is my problem. Eclipse is telling me that I have unused variable "i" in line 9. This program is intended to take an input file of 100 numbers and order them. There is a file output in my directory, out.txt which does it. But no file appears in terminal. Maybe call it again? I don't know, this is driving me nuts. Thanks forums. you are great.
The unused variable isn't a big deal, but you could simply delete the unwanted 'i' to get rid of the warning message.
As for the output appearing in the terminal. Well, apart from a couple of messages, all the output is sent to the output file "out.txt" in function print_data().
The main problem (if you want to consider it a problem) is that the unsorted data is output at line 66. Then at line 68 that same file is used to output the sorted data. Thus, unless you pause the program after line 66, you won't ever see the unsorted data as it gets overwritten by the sorted version.
In any case, the original input file contained the unsorted data. But if you want to keep both outputs, use two different file names (maybe pass the filename as a parameter to the function print_data).