fork(1) download
  1. import math
  2. t = int(input())
  3.  
  4. i=0
  5. ans=0
  6.  
  7. for i in range(t):
  8. a,b,c = input().split()
  9. a,b,c = int(a), int(b), int(c)
  10.  
  11. ans = math.ceil(c/a)
  12.  
  13. an2 = (c/b)
  14. print(int(ans + an2))
Success #stdin #stdout 0.03s 9856KB
stdin
4
2 4 8
3 4 6
4 3 6
10 12 5
stdout
6
3
4
1