You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/* You're given a number N. If N is divisible by 5 or 11 but not both then print "ONE"(without quotes). If N is divisible by both 5 and 11 then print "BOTH"(without quotes). If N is not divisible by 5 or 11 then print "NONE"(without quotes).
2
+
3
+
Input:
4
+
First-line will contain the number N.
5
+
Output:
6
+
Print the answer in a newline.
7
+
8
+
Constraints
9
+
1≤N≤103
10
+
Sample Input 1:
11
+
50
12
+
Sample Output 1:
13
+
ONE
14
+
Sample Input 2:
15
+
110
16
+
Sample Output 2:
17
+
BOTH
18
+
Sample Input 2:
19
+
16
20
+
Sample Output 2:
21
+
NONE
22
+
EXPLANATION:
23
+
In the first example, 50 is divisible by 5, but not 11.
24
+
In the second example, 110 is divisible by both 5 and 11.
25
+
In the third example, 16 is not divisible by 5 or 11. */
0 commit comments