Let T = time
L = length
N = number of students
Then, T = kL/N, for some constant, k.
Since T = 2 when L = 4 and N = 12, we have 2 = k(4)/12
2 = (1/3)k So, k =6
Therefore, T = 6L/N
When N = 50 and L = 40, T = 6(40)/50 = 4.8 hours