import math
a = int(input())
for i in range(a):
b,d,c = map(int,input().split()) m=math.sqrt(b**2 + d**2) / 25 + c*1.5 p = math.ceil(m)print(p)