Tough homework assignment eh?
Perhaps a good start might be to look at breadth-first pathfinding algorithms- maybe something like a flood-fill approach would be useful for this?
Edit: So if it just looks like a homework assignment, maybe I can be more helpful...
I would first look to define a rectangle containing the line and the points that could be within it as that may enable us to get rid of a large number of points that are nowhere near our line.
For each point you could then create a square, representing the list of points within the radius of that point. This is again a way of reducing the number of elements to search.
Unfortunately I don't know enough geometry to be aware of a clever way of deciding whether a list of points fall inside or outside of a circle aside from simply calculating the distance between them and the centre of the circle through basic trig- I'm sure there is one. By using the aforementioned simple subdivision or some variant on it you should find that you can pre-emptively reduce the number of possible points that need to be searched through.
Also if you keep all your points to search in one list and remove the ones that are hits for the first circle, when it comes to measure subsequent shapes. I've used a brute-force version of this to do simple postcode-distance checks based on location data - that is documented in quite a few places online, but running it down a path would probably be quite computationally expensive.
This geometric approach would probably be better for a situation where you weren't doing a lot of repeated searches- if there are many in a row you might want to organise your ponts into a network so that you can use standard pathfinding on them. It would be worth doing some protoyping to see which is more efficient, but I would expect that if you were to create an appropriate network to represent your data you could then be more flexible in how you search it.