Each line of the file must contain either a comment, white-space only, or a single file element. I have made this format as simple as possible to parse, with little room for variation except white space and number of lights, spheres, etc. One way you can implement some pretty simple parsing is as follows. Write a simple procedure to get each line of input. Here, X is a point on the sphere, C is the center, and r is the radius.
P is the start of the ray and V is the direction.
Final Words of Encouragement Good luck on your first assignment. I hope that in addition to being a lot of work, it provides you with some fun and satisfying moments. Remember that I'm available to answer questions in class, by e-mail, or by appointment.