Fitting circles
Practice
3.4 (82 votes)
Basic programming
Basics of implementation
Implementation
Problem
56% Success 19157 Attempts 10 Points 1s Time Limit 256MB Memory 1024 KB Max Code

You are given a rectangle of length \(a\) and width \(b\). You are required to determine a circle that contains the maximum circumference that fits inside the rectangle. This type of circle is called a big circle. Your task is to determine the maximum number of big circles that can fit inside the rectangle. 

Input format

  • First line: An integer \(t\) denoting the number of test cases
  • First line of each test case: Integers \(a\) and \(b\)

Output format

For each test case, print the answer on a new line denoting the maximum number of big circles that can fit in the provided rectangle.  

Constraints

\(1 ≤ t ≤ 1000\\ 1 ≤ a,b ≤ 10^9\)

Please login to use the editor

You need to be logged in to access the code editor

Loading...

Please wait while we load the editor

Loading...
Results
Custom Input
Run your code to see the output
Submissions
Please login to view your submissions
Similar Problems
Points:10
100 votes
Tags:
Easy
Points:10
29 votes
Tags:
Basic ProgrammingC++
Points:10
79 votes
Tags:
Basic Programming