Operative Task Force
Problem Statement
In the secretive world of espionage, forming the right task force can make the difference between mission success and failure. You are assigned as the head of a covert operations unit, and your task is to assemble as many task forces as possible from a pool of available agents. Each agent comes with a unique strength rating.
A task force is valid if it contains at least one agent and, if the group consists of agents with the smallest strength being , then the product
must be at least a specified threshold . Note that an agent can be part of at most one task force, and it is not necessary to use every agent.
Your goal is to determine the maximum number of valid task forces that can be formed given the strengths of the agents and the threshold .
Input Format
The first line contains a single integer () denoting the number of test cases.
Each test case is described by two lines:
- The first line contains two space-separated integers and (, ), where is the number of agents.
- The second line contains space-separated integers () representing the strength of each agent.
It is guaranteed that the sum of all over all test cases does not exceed .
Output Format
For each test case, print a single integer representing the maximum number of valid task forces that can be formed.
Examples
Input
5 10
7 11 2 9 5
Output
2
Input
4 8
2 4 2 3
Output
1
Code Editor
Submit a solution. Authentication is required to create submissions.