fork(1) download
  1. def ileZer(n)
  2. ile=0
  3. while n>=5 do
  4. ile+=n/5
  5. n=n/5
  6. end
  7. ile
  8. end
  9.  
  10. t=gets.to_i
  11. while t>0 do
  12. t=t-1
  13. n=gets.to_i
  14. puts ileZer(n)
  15. end
Success #stdin #stdout 0.01s 5772KB
stdin
5
0
1
10
100
10000000
stdout
0
0
2
24
2499999