Let a be the number of students, b be the number of buses, and c the number of students per bus for the second try.

For more generality replace 33 with n. We then have that (a-1)/n = b (first trip) and a/(b-1) = c (second trip) ==> a = n*b + 1 ==> c = a/(b-1) = (n*b+1)/(b-1) = (n*b-n)/(b-1) + (n+1)/(b-1) = n + (n+1)/(b-1). From this all solutions may be derived, and they are

(a,b,c) = (n*(n+1)/d + n + 1, (n+1)/d + 1, n + d)

where d | (n+1) (i.e. d divides n+1). The answer with smallest a results from letting d=n+1 and it is (a,b,c)=(2n+1, 2, 2n+1); likewise the answer with largest a is ((n+1)^2,n+2,n+1).

In the specific case we have n=33, so n+1=34=2*17 and we have

4 answers. They are
(a,b,c) = (67,2,67), (100,3,50), (595,18,35), (1156,35,34)

--Chris Long (clong@cnj.digex.com)

#### PHP Warning

lib/DbaDatabase.php:122: Warning: dba_delete() [<a href='function.dba-delete'>function.dba-delete</a>]: You cannot perform a modification to a database without proper access (...repeated 290 times)