Combinational circuit problem

1. The problem statement, all variables and given/known data
Rods of varying length l such that 0.9L<= l <= 1.1L travel on a conveyor whose width is 1.1L. Mechanical arm pushes the rods with spec +- 5% (0.95 <= l <= 1.05L) to one side. Rods too short or too long stay on the belt. Suppose that the traveling rods are parallel to each other, but are not aligned at either end. Suppose that u can use at most 10 light barriers to activate the arm. Design a combinational logic circuit to activate the arm such that as many rods as possible which fulfill the requirement 0.95 <= l <= 1.05L are detected.

2. Relevant equations

3. The attempt at a solution
Ok, so basically, if i knew where to place the light barriers to detect which bars were within spec I could finish the rest of this problem. So far, the only solution i can think of is having 5 light barriers on both sides of the belt, separated by 0.3L, however, i don't think that this is a very accurate method, and was wondering if anyone else has any good ideas about how to solve this.
Thanks!!