-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathGood_Turn.py
More file actions
26 lines (25 loc) · 1015 Bytes
/
Good_Turn.py
File metadata and controls
26 lines (25 loc) · 1015 Bytes
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
# Good Turn
# Chef and Chefina are playing with dice. In one turn, both of them roll their dice at once.
# They consider a turn to be good if the sum of the numbers on their dice is greater than 6
#
# Given that in a particular turn Chef and Chefina got X and Y
# Y on their respective dice, find whether the turn was good.
#
# Input Format
# The first line of input will contain a single integer T
# T, denoting the number of test cases.
# Each test case contains two space-separated integers X and Y
# Y — the numbers Chef and Chefina got on their respective dice.
# Output Format
# For each test case, output on a new line, YES, if the turn was good and NO otherwise.
#
# Each character of the output may be printed in either uppercase or lowercase. That is, the strings NO, no, nO, and No will be treated as equivalent.
t = int(input())
sum=0
for i in range(0,t):
x,y = map(int,input().split())
sum=(x+y)
if(sum>6):
print("YES")
else:
print("NO")