In order to test your program, you'll need another small program that will let you put integers into a file. You might write it where it asks the user for how many numbers to put into the file and them read them into and array which you then write to the file.