It really does not matter if the numbers are on a separate line or just separated by a space. That part is minor.
Start with some code that creates a file stream and opens the file.
Then you could use a loop to read the file.
Your choice then would be either to read into a variable and put the variable into the array or read directly into the array.
Work in small parts or steps. Compile often and check for errors, so that you only have a few errors to correct. Test as often as you can to see what is working.
#include <Necessary header files>
define file stream. Can open file here.
Open file if you have not done so yet.
Read the first number.
When that works create a loop to read the entire file.
Once this works you can continue with the rest of the program.
When you have that part working or not post you code.