-
Notifications
You must be signed in to change notification settings - Fork 0
/
edu_round_151_div2.java
37 lines (35 loc) · 1.02 KB
/
edu_round_151_div2.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import java.util.Scanner;
public class edu_round_151_div2 {
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int t = sc.nextInt();
while(t --> 0){
int n = sc.nextInt();
int k = sc.nextInt();
int x = sc.nextInt();
boolean flag = false;
for(int i = k;i >= 1;i--){
if(i == x){
continue;
}
else {
if(n % i == 0){
// int temp = n % i;
// int count = 0;
// while(temp >= 0){
// count += temp;
// }
flag = true;
break;
}
}
}
if(flag){
System.out.println("YES");
}
else{
System.out.println("NO");
}
}
}
}