**Physical Address**

304 North Cardinal St.

Dorchester Center, MA 02124

In a coding contest, there are two types of problems:

- Easy problems, which are worth 1 point each
- Hard problems, which are worth 2 points each

To qualify for the next round, a contestant must score at least *X* points. Chef solved *A* Easy problems and *B* Hard problems. Will Chef qualify or not?

- The first line of input contains a single integer
*T*, denoting the number of test cases. The description of*T*test cases follows. - Each test case consists of a single line of input containing three space-separated integers —
*X*,*A*, and*B*.

For each test case, output a new line containing the answer — `Qualify`

if Chef qualifies for the next round, and `NotQualify`

otherwise.

Each character of the answer may be printed in either uppercase or lowercase. For example, if the answer is `Qualify`

, outputs such as `qualify`

, `quALiFy`

, `QUALIFY`

and `QuAlIfY`

will also be accepted as correct.

- 1≤
*T*≤100 - 1≤
*X*≤100 - 0≤
*A*,*B*≤100

**Input**: 3
15 9 3
5 3 0
6 2 8
**Output**: Qualify
NotQualify
Qualify

**Test Case 1:** Chef solved 9 easy problems and 3 hard problems, making his total score 9⋅1+3⋅2=15. He needs at least 15 points to qualify, which he has and hence he qualifies.

**Test Case 2:** Chef solved 3 easy problems and 0 hard problems, making his total score 3⋅1+0⋅2=3. He needs at least 5 points to qualify, which he doesn’t have and hence doesn’t qualify.

**Test Case 3:** Chef solved 2 easy problems and 8 hard problems, making his total score 2⋅1+8⋅2=18. He needs at least 6 points to qualify, which he has and hence he qualifies.

```
#include <iostream>
using namespace std;
int main() {
int t;
cin>>t;
while(t--) {
int x, a, b ;
cin>>x>>a>>b;
if( a + 2*b >= x) {
cout<<"Qualify\n";
}
else {
cout<<"NotQualify\n";
}
}
return 0;
}
```

```
t = int(input())
for _ in range(t):
x, a, b = map(int, input().split())
score = a + b*2
if score >= x:
print('Qualify')
else:
print('NotQualify')
```

```
/* package codechef; // don't place package name! */
import java.util.*;
import java.lang.*;
import java.io.*;
/* Name of the class has to be "Main" only if the class is public. */
class Codechef
{
public static void main (String[] args) throws java.lang.Exception
{
Scanner sc=new Scanner(System.in);
int T=sc.nextInt();
for(int i=0;i<T;i++)
{
int x=sc.nextInt();
int y=sc.nextInt();
int z=sc.nextInt();
int a=y+z*2;
if(a>=x)
System.out.println("Qualify");
else
System.out.println("NotQualify");
}
}
}
```

In our experience, we suggest you solve this Qualify the round CodeChef Solution and gain some new skills from Professionals completely free and we assure you will be worth it.

If you are stuck anywhere between any coding problem, just visit Queslers to get the Qualify the round CodeChef Solution

I hope this Qualify the round CodeChef Solution would be useful for you to learn something new from this problem. If it helped you then don’t forget to bookmark our site for more Coding Solutions.

This Problem is intended for audiences of all experiences who are interested in learning about Data Science in a business context; there are no prerequisites.

Keep Learning!

**More Coding Solutions >>**