# Arup Guha
# 7/24/2013
# Solution to SI@UCF Contest Question: Pientology

import math

def main():

    file = open("pie.in", "r")
    numCases = int(file.readline())

    for i in range(numCases):

        # Extract tokens and calculate volume of one pie.
        tokens = file.readline().split()
        volume = math.pi*(float(tokens[0])**2)*float(tokens[1])

        # The desired answer is the integer division here.        
        print(int((float(tokens[2]))//volume))

    file.close()

main()
