Problem:


  MathJax.Hub.Config({ tex2jax: { inlineMath: [["$","$"], ["\\(","\\)"]], processEscapes: true }});

Circle in a Rectangle

  Write a program which reads a rectangle and a circle, and determines whether the circle is arranged inside the rectangle. As shown in the following figures, the upper right coordinate $(W, H)$ of the rectangle and the central coordinate $(x, y)$ and radius $r$ of the circle are given.

Input

  Five integers $W$, $H$, $x$, $y$ and $r$ separated by a single space are given in a line.

Output

  Print "Yes" if the circle is placed inside the rectangle, otherwise "No" in a line.

Constraints

  
$ -100  \leq x, y \leq 100$

  
$ 0  < W, H, r \leq 100$

Sample Input 1

5 4 2 2 1

Sample Output 1

Yes

Sample Input 2

5 4 2 4 1

Sample Output 2

No



Sample input:
5 4 2 2 1


Sample output:
Yes

Submission status: Accepted

Solution code:
def is_in(W, H, x, y, r):
    x_min = r
    x_max = W - r
    y_min = r
    y_max = H - r
    if x_min <= x <= x_max and y_min <= y <= y_max:
        return 'Yes'
    return 'No'


if __name__ == "__main__":
    W, H, x, y, r = map(int, input().split())
    print(is_in(W, H, x, y, r))

Submission status: Accepted

Solution code:
w,h,x,y,r=map(int,input().split())
if x>=r and x<=w-r and y>=r and y<=h-r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())

if x<=0 or y<=0:
  print('No')
elif x+r <= w and y+r <= h:
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
import sys

#tmp= int(input())
tmp = input().split()
W,H,x,y,r = list(map(lambda a: int(a), tmp))


if(x<r):
    print("No")
    sys.exit()
if(x>W-r):
    print("No")
    sys.exit()
if(y<r):
    print("No")
    sys.exit()
if(y>H-r):
    print("No")
    sys.exit()
print("Yes")

Submission status: Accepted

Solution code:
a = input().split()
#a[0]:W a[1]:H a[2]:x a[3]:y a[4]:r
if 0<=int(a[2])-int(a[4]) and int(a[2])+int(a[4])<=int(a[0]) and\
    0<=int(a[3])-int(a[4]) and int(a[3])+int(a[4])<=int(a[1]):
        print("Yes")
else:
        print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if W-r >= x and H-r >= y and x - r >= 0 and y - r >= 0:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if x >= r and (W - r) >= x:
    if y >= r and (H - r) >= y:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().split())

if((x-r) < 0 or (y-r) < 0 or (x+r) > W or (y+r)> H):
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
def judge(p, r, l):
    rowBorder = r
    highBorder = l -r
    ret = False
    if p <= highBorder and p >= rowBorder:
        ret = True
    
    return ret

def circleinRec(w, h, x, y, r):
    #W
    retW = judge(x, r, w)

    #H
    retH = judge(y, r, h)

    if retW == True and retH == True:
        return True

    else:
        return False

def main():
    val = input().split()
    val = [int(n) for n in val]
    ret = circleinRec(val[0], val[1], val[2], val[3], val[4])
    if ret == True:
        print('Yes')

    else:
        print('No')

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
w, h, x, y, r  = map(int, input().split())

ans = "Yes"
if (x - r) < 0: ans = "No"
if (x + r) > w: ans = "No"
if (y - r) < 0: ans = "No"
if (y + r) > h: ans = "No"

print(ans)

Submission status: Accepted

Solution code:
a = list(map(int,input().split()))

if 0 <= a[2] + a[4] <= a[0] and 0 <= a[3] + a[4] <= a[1] and \
    0 <= a[2] - a[4] <= a[0] and 0 <= a[3] - a[4] <= a[1]:
    print('Yes')

else:
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())

if x - r >= 0 and x + r <= W and y - r >= 0 and y + r <= H:
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int,input().split())

if x+r<= W and y+r<=H and x>=r and y>=r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = list(map(int, input().split()))
if r <= x and r <= y and x <= W - r and y <= H - r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())

if r <= x and r <= y and x <= W-r and y <= H -r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())

if ( x - r ) < 0:
  print("No")
elif ( y - r) < 0:
  print("No")
elif w < ( x + r ):
  print("No")
elif h <  ( y + r ):
  print("No")
else:
  print("Yes")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x - r >= 0 and x + r <= W and y - r >= 0 and y + r <= H:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w,h,x,y,r=map(int,input().split())

sum_x=x+r
sum_y=y+r
f=0
if r>x or r>y:
    f=1
if abs(sum_x)>w:
    f=1
if abs(sum_y)>h:
    f=1
if f==0:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().split())
if x >= r and y >= r and W-x >= r and H-y >= r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int,input().split())
if x-r<0 or x+r>w or y-r<0 or y+r>h:
  print("No")
else:
  print("Yes")

Submission status: Accepted

Solution code:
s = input()
t = s.split()
W,H,x,y,r = int(t[0]),int(t[1]),int(t[2]),int(t[3]),int(t[4])
sx,ex = x-r,x + r
sy,ey = y-r,y+r
if sx>=0 and ex<=W and sy >=0 and ey <= H:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
i = input()
W, H, x, y, r = map(int, i.split())

if x-r >= 0 and y-r>=0 and x+r<=W and y+r<=H:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = [int(x) for x in input().split()]

X = 0 <= x - r and x + r <= W
Y = 0 <= y - r and y + r <= H

if X and Y == 1:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int, input().split())

if (x+r <= w and x-r >= 0) and (y+r <= h and y-r >= 0):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split(' '))

if x + r <= W and x - r >= 0 and y + r <= H and y - r >= 0:
  print('Yes')
else:
  print('No')

Submission status: Accepted

Solution code:
w,h,x,y,r=map(int,input().split())
if r <= x <= w-r and r <= y <= h-r:
         print("Yes")
else:
         print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if (r <= x <= (W - r)) & (r <= y <= (H - r)):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x + r <= W and y + r <= H and x - r >= 0 and y - r >= 0:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
hoge = list(map(int,input().split()))
w,h,x,y,r = hoge[0],hoge[1],hoge[2],hoge[3],hoge[4]

if x < r or y < r or x + r > w or y + r > h:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int,input().split())

if x >= r and y >= r and x+r <= w and y+r <= h:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().split())

if x < r:
    print('No')
elif x > W-r:
    print('No')
elif y < r:
    print('No')
elif y > H-r:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
w, h, x, y, r = [int(i) for i in input().split()] # 5 4 2 2 1
if x - r >= 0 and x + r <= w:
    if y - r >= 0 and y + r <= h:
        print("Yes")
    else:
        print("No")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())

if(r<=x<=W-r and r<=y<=H-r):
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
if y+r<=H and y-r>=0:
    if x+r<=W and x-r>=0:
        print("Yes")
        exit()
print("No")

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())
if x >= r and (x + r) <= w and y >= r and (y + r) <= h:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if r <= x <= W - r and r <= y <= H - r :
    print('Yes')
else :
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
print("YNeos"[not(x>0 and y>0 and x-r >= 0 and y-r >= 0 and x + r <= W and y + r <= H)::2])

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
w, h, x, y, r = map(int,input().split())

flag = False
if 0 <= x <= w - r and 0 <= y <= h - r:
    flag = True
if flag:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

W, H, x, y, r = map(int, input().split())

if x + r <= W and x - r >= 0 and y + r <= H and y - r >= 0:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())

if 0 <= x-r and x+r <= w and 0 <= y-r and y+r <= h:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y,r = map(int, input().split())

if x + r > W or y + r > H:
    print("No")

elif x - r < 0 or y - r < 0:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
if (r<=x<=W-r)and(r<=y<=H-r):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

a = 'Yes'
# up
if H < y + r:
    a = 'No'

# bottom
if y - r < 0:
    a = 'No'

# left
if x - r < 0:
    a = 'No'

# right
if W < x + r:
    a = 'No'

print(a)

Submission status: Accepted

Solution code:
input_line = list(map(int,input().split()))

W = input_line[0]
H = input_line[1]
x = input_line[2]
y = input_line[3]
r = input_line[4]
flag = True

if x-r < 0 or x+r > W:
    flag = False
if y-r < 0 or y + r > H:
    flag = False
if flag:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
print('Yes' if 0 <= x-r and x+r <= W and 0 <= y-r and y+r <= H else 'No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x >= r and x <= W - r and y >= r and y <= H - r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if 0 <= x + r <= W and 0 <= y + r <= H and 0 <= x - r <= W and 0 <= y - r <= H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x-r >= 0 and x+r <= W and y-r>=0 and y+r <=H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = list(map(int, input().split()))

if ((x + r) <= W) and ((y + r) <= H)\
	 and (0 <= (x - r)) and (0 <= (y - r)):
	print("Yes")
else:
	print("No")

Submission status: Accepted

Solution code:
i = input()
W, H, x, y, r = map(int, i.split())
if (0 <= x - r <= W) and (0 <= x + r <= W) and (0 <= y - r <= H) and (0 <= y + r <= H):
	print("Yes")
else:
	print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r=(int(x) for x in input().split())
if x+r>W or x-r<0 or y+r>H or y-r<0:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
w, h, x, y, r = input().split()
w, h, x, y, r = int(w), int(h), int(x), int(y), int(r)
if x - r >= 0 and y - r >= 0 and x + r <= w and y + r <= h:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r = [int(i) for i in input().split()]


if (0 <= x - r ) and (x + r <= w) and (0 <= y - r) and  (y + r <= h):
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split(' '))
if 0 <= x - r and 0 <= y - r and W >= x + r and H >= y + r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
a,b,c,d,e = input().split()
a = int(a)
b = int(b)
c = int(c)
d = int(d)
e = int(e)
if a >= c+e and b >= d+e and c>0 and d>0:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if x + r > W or y + r > H or x - r < 0 or y - r < 0 or x - r < 0 or y - r < 0:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
data = list(map(int, input("").split()))

x_max = data[2] + data[4]
x_min = data[2] - data[4]
y_max = data[3] + data[4] 
y_min = data[3] - data[4] 

if x_min >= 0 and x_max <= data[0] and y_min >= 0 and y_max <= data[1]:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())

if x - r < 0:
    print('No')
elif y - r < 0:
    print('No')
elif x + r > w:
    print('No')
elif y + r > h:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if x + r <= W and x - r >= 0 and y + r <= H and y - r >= 0:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int, input().split())

if x+r > w or x-r < 0:
    print("No")

elif y+r > h or y-r < 0:
    print("No")

else:
    print("Yes")

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
if x+r>W or y+r>H or x-r<0 or y-r<0:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x-r < 0:
    print ("No")
elif x + r > W:
    print ("No")
elif y-r < 0:
    print ("No")
elif y+r > H:
    print ("No")
else:
    print ("Yes")

Submission status: Accepted

Solution code:
l = input().split()
W = int(l[0])
H = int(l[1])
x = int(l[2])
y = int(l[3])
r = int(l[4])

if (x >= r and y >= r) and (x <= (W - r) and y <= (H - r)):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if r<=x and x<=W-r and r<=y and y<=H-r:
	print("Yes")
else:
	print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
if((x-r)<0 or (y-r)<0 or (x+r)>W or (y+r)>H):
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
import sys
import itertools

# import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

W, H, x, y, r = map(int, readline().split())

print('Yes' if 0 <= x - r and x + r <= W and 0 <= y - r and y + r <= H else 'No')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if (x-r)<0 or (x+r)>W or (y-r)<0 or (y+r)>H:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
w,h, x, y, r = map(int, input().split())

if x + r <= w and x -r >= 0 and y - r >= 0 and y + r <= h:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
if((x-r)<0 or (y-r)<0 or (x+r)>W or (y+r)>H):
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
x1 = x + r
x2 = x - r
y1 = y + r
y2 = y - r

if x1 <= W and y1 <= H and 0 <= x2 and 0 <= y2:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = input().split()
W,H,x,y,r = int(W),int(H),int(x),int(y),int(r)

if r <= x <= W-r and r <= y <= H-r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int, input().split())
if (0<= x-r) and (x+r <= w) and (0 <= y-r) and (y+r <= h):
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r = list(map(int, input().split() ))
if r<=x and x+r<=W and r<=y and y+r<=H:
 print("Yes")
else:
 print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x-r < 0 or y-r < 0 or x+r > W or y+r > H:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())

if x - r >= 0 and x + r <= w and y - r >= 0 and y + r <= h:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r=map(int,input().split())
print("Yes" if r<=x and x<=w-r and r<=y and y<=h-r else "No")

Submission status: Accepted

Solution code:
#!python3

iim = lambda: map(int, input().rstrip().split())

def resolve():
    w, h ,x, y, r = iim()

    print("Yes" if r <= x <= w-r and r <= y <= h-r else "No")

if __name__ == "__main__":
    resolve()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

W,H,x,y,r = list( map( int, input().split() ) )

#-----
if x >= r and y >= r and x <= (W-r) and y <= (H-r):
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if x + r <= W and y + r <= H:
    if x - r >= 0 and y - r >= 0:
        print("Yes")
    else:
        print("No")
else:print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r=map(int,input().split())
if 0<x+r<w+1 and 0<y+r<h+1:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = input().split()
if int(x) > int(W) or int(y) > int(H):
  print("No")
elif int(x) == int(W) or int(y) == int(H):
  print("No")
elif int(W) > int(x) - int(r) >= 0 and int(H) > int(y) - int(r) >= 0:
  print("Yes")
elif int(W) > int(x) + int(r) >= 0 and int(H) > int(y) + int(r) >= 0:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
input_num = input().split()
W,H,x,y,r = [int(n) for n in input_num]
# 0<=x<=(W-r),0<=y<=(H-r)
if (r<=x)&(x<=(W-r))&(r<=y)&(y<=(H-r)):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())

if x >= r and x <= W-r and y >= r and y <= H-r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
num = input().split()

W = int(num[0])
H = int(num[1])
x = int(num[2])
y = int(num[3])
r = int(num[4])

if W - r >= x > 0 and H - r >= y > 0:
  print("Yes")

else:
  print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r=(int(i) for i in input().split())

if r<=x<=W-r and r<=y<=H-r:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
w, h, x, y, r = [int(i) for i in input().split()]
ans = "Yes"
if x - r < 0 or x + r > w or y - r < 0 or y + r > h:
    ans = "No"
print(ans)

Submission status: Accepted

Solution code:
W, H, x, y, r=input().split()
W=int(W)
H=int(H)
x=int(x)
y=int(y)
r=int(r)
if H >= y+r and W >= x+r and 0 <= y-r and 0 <= x-r :
    print("Yes")
else :
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())

if ( 0 <= x - r and x + r <= W and 0 <= y - r and y + r <= H):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
inp = input()

strw, strh, strx, stry, strr = inp.split()

w = int(strw)
h = int(strh)
x = int(strx)
y = int(stry)
r = int(strr)

if x > 0 and y > 0 and w - x >= r and h - y >= r:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if (W < x+r) or (r > x) or (H < y+r) or (r > y):
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if x >= r and y >= r and x <= W-r and y <= H-r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
rec_dx, rec_dy, cir_x, cir_y, cir_r = [int(x) for x in input().split()]

cir_left = cir_x - cir_r
cir_right = cir_x + cir_r
cir_up = cir_y + cir_r
cir_down = cir_y - cir_r

if cir_left < 0:
    print("No")
elif cir_right > rec_dx:
    print("No")
elif cir_up > rec_dy:
    print("No")
elif cir_down < 0:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().split())
if 0 <= x-r and x+r <= W and 0 <= y-r and y+r <= H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())

if x-r >= 0:
    if x+r <= w:
        if y-r >=0:
            if y+r<=h:
                print('Yes')
            else:
                print('No')
        else:
            print('No')
    else:
        print('No')
else:
    print('No')

Submission status: Accepted

Solution code:
width, height, x, y, r = list(map(int, input().split(' ')))

def isCircleInRect(w, h, x, y, r):
    isInX = x - r >= 0 and x + r <= w
    isInY = y - r >= 0 and y + r <= h
    return isInX and isInY

result = 'Yes' if isCircleInRect(width, height, x, y, r) else 'No'
print(result)

Submission status: Accepted

Solution code:
W,H,x,y,r = list(map(int, input().split()))
answer = 'Yes'
if x<r:
    answer = 'No'
if y<r:
    answer = 'No'
if W < x+r:
    answer = 'No'
if H < y+r:
    answer = 'No'
print(answer)

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())

if r<=y<=H-r and r<=x<=W-r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int, raw_input().split())
if r <= x <= (w-r):
    if r <= y <= (h-r):
        print("Yes")
    else:
        print("No")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int,input().split()) 
x_min = x - r
x_max = x + r
y_min = y - r
y_max = y + r
if 0 <= x_min and \
    x_max <= W and \
    0 <= y_min and \
    y_max <= H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())

if r <= x <= W -r and  r <= y <= H - r:
    print("Yes")

else :
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())

if x - r < 0 or y - r < 0 or x + r > W or y + r > H:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
print(["No","Yes"][x + r <= W and x - r >= 0 and y + r <= H and y - r >= 0])

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
ans = True

ans = False if x-r < 0 else ans
ans = False if x+r > W else ans
ans = False if y-r < 0 else ans
ans = False if y+r > H else ans

print("Yes") if ans else print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split(' '))
if x + r > W or x - r < 0 or y + r > H or y - r < 0:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
W,H,x,y,r=map(int,input().split())
if r<=x<=W-r and r<=y<=H-r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if (x+r)>W or (x-r)<0 or (y+r)>H or (y-r)<0:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int,input().split())

if r <= x <= w - r and r <= y <= h - r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if H >= y+r and W >= x+r and 0 <= y-r and 0 <= x-r:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w, h, x, y, r = map(int, input().split())
if(x - r >= 0 and y - r >= 0 and x + r <= w and y + r <= h):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x > 0 and y > 0 and x + r <= W and y + r <= H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int,input().split())

if x>=r and x+r<=w and y>=r and y+r<=h:
	print("Yes")
else:
	print("No")

Submission status: Accepted

Solution code:
import sys

l = input()
w, h, x, y, r = map(int, l.split())

if x+r>w or x-r<0:
    print("No")
elif y+r>h or y-r<0:
    print("No")
else :
    print("Yes")

Submission status: Accepted

Solution code:
# ITP1_2_D
# Circle in a Rectangle
# http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_2_D
# encode : utf-8
W, H, x, y, r = map(int, input().split())
if r <= x <= (W-r) and r <= y <= (H-r):
    print('Yes')
else :
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = list(map(int, input().split()))
print('Yes' if 0 <= x - r <= x + r <= W and 0 <= y - r <= y + r <= H else 'No')

Submission status: Accepted

Solution code:
def IsCircleInRect(W, H, x, y, r):

    x_left = x
    x_right = W - x
    y_upper = H - y
    y_lower = y

    if (x < 0) | (y < 0) | (x > W) | (y > H):
        print("No")
    elif (x_left < r) | (x_right < r) | (y_upper < r) | (y_lower < r):
        print("No")
    else:
        print("Yes")

if __name__ == "__main__":

    param = input()
    param = param.split(" ")

    W = int(param[0])
    H = int(param[1])
    x = int(param[2])
    y = int(param[3])
    r = int(param[4])

    IsCircleInRect(W, H, x, y, r)

Submission status: Accepted

Solution code:
w,h,x,y,r=map(int,input().split())
if(r<=x and x<=w-r and r<=y and y<=h-r):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
integer = list(map(int, input().split(" ")))
W = integer[0]
H = integer[1]
x = integer[2]
y = integer[3]
r = integer[4]

if x < 0 or y < 0:
    print("No")
       
elif W - x >= r:
    if H - y >= r:
        print("Yes")
    else:
        print("No")
      
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if x-r < 0:
    print("No")
elif x + r > W:
    print("No")
elif y-r < 0:
    print ("No")
elif y+r > H:
    print ("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
inlist = input().split()
w,h, x,y,r = (int(x) for x in inlist)

if r <= x <= w-r and r <= y <= h-r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if 0 <= x-r and x+r <= W and 0 <= y-r and y+r <= H:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int,input().split())

if(x + r > W or x - r < 0):
    print("No")
elif(y + r > H or y - r < 0):
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if x>=r and x<=W-r and y>=r and y<=H-r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
from collections import deque
import sys

sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep="\n")

def main():
    w,h,x,y,r=list(map(int,input().split()))
    if min(x,y)-r<0 or x+r>w or y+r>h:
        print("No")
    else:
        print("Yes")
    

main()

Submission status: Accepted

Solution code:
list=input().split()
w=int(list[0])
h=int(list[1])
x=int(list[2])
y=int(list[3])
r=int(list[4])

if w>=x+r and x-r>=0:
  if h>=y+r and y-r>=0:
    print("Yes")
  else:
    print("No")
else:
  print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if r <= x <= W-r and r <= y <= H-r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
chk1 = r <= x <= W - r
chk2 = r <= y <= H - r
chk0 = "Yes" if (chk1 == True and chk2 == True) else "No"
print(chk0)

Submission status: Accepted

Solution code:
W, H, x, y, r = (int(x) for x in input().split())

def judge(W, H, x, y, r):
    if -100 <= x and x <= 100:
        if -100 <= y and y <= 100:
            if 0 < W and W <= 100:
                if 0 < H and H <= 100:
                    if 0 < r and r <= 100:
                        return True

if judge(W, H, x, y, r):
    if x + r <= W and y + r <= H and 0 <= x - r and 0 <= y - r:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())
if x >= r and y >= r and (x+r) <= W and (y+r) <= H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
a = list(map(int,input().split()))
W = a[0]
H = a[1]
x = a[2]
y = a[3]
r = a[4]
if x-r >= 0 and x+r <= W and y-r >= 0 and y+r <= H:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if x - r >= 0 and x + r <= W and y - r >= 0 and y + r <= H:
    print('Yes')
else :
    print('No')

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int,input().split())
if x < 0 or y < 0:
    print("No")
else:
    if W < x + r or H < y + r:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
a = input().split()

W = a[0]
H = a[1]
x = a[2]
y = a[3]
r = a[4]

if int(x)+int(r) > int(W) or int(x)-int(r) < 0:
    print("No")
else:
    if int(y)+int(r) > int(H) or int(y)-int(r) < 0:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
w, h, x, y, r = [int(i) for i in input().split()]
ans = None

if x+r<=w and x-r>=0 and y+r<=h and y-r>=0:
    ans = "Yes"
else:
    ans = "No"
    
print(ans)

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().split())
if x >= r and y >= r and x <= W - r and y <= H - r:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
w,h,x,y,r=list(map(int,input().split()))
if r<=x and x+r<=w and r<=y and y+r<=h:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
w,h,x,y,r = map(int, input().split())

if x-r >= 0 and x+r <= w and y-r >= 0 and y+r <= h:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if x - r >= 0 and x + r <= W and y - r >= 0 and y + r <= H:
    print('Yes')
else:
    print('No')

Submission status: Accepted

Solution code:
W, H, x, y, r = map(int, input().split())

if r <= x <= W - r and r <= y <= H - r :
    print('Yes')
else :
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().strip().split(' '))
print('Yes' if r <= x <= W-r and r <= y <= H-r else 'No')

Submission status: Accepted

Solution code:
[i for i in [dict()] if not((i.update({'o': list(map(int, input().split()))}) or i.update({'w': i['o'][0]}) or i.update({'h': i['o'][1]}) or i.update({'x': i['o'][2] + i['o'][4]}) or i.update({'y': i['o'][3] + i['o'][4]}) or None) or (print('No') if (i['x']<=0 or i['w']<i['x']) or (i['y']<=0 or i['h']<i['y']) else print('Yes')) or None)]

Submission status: Accepted

Solution code:
l = list(map(int, input().split()))
W,H,x,y,r =l[0],l[1],l[2],l[3],l[4]
Wr = W - r
Hr = H - r
if r<= x <= Wr and r<= y <= Hr:
    print("Yes")

else:
    print("No")

Submission status: Accepted

Solution code:
W,H,x,y,r = map(int, input().split())
x_right = x + r
x_left = x - r
y_above = y + r
y_below = y - r

if (x_right <= W) and (x_left >= 0) and (y_above <= H) and (y_below >= 0):
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
Input = input().split()
W = int(Input[0])
H = int(Input[1])
x = int(Input[2])
y = int(Input[3])
r = int(Input[4])
if x >= r and y >= r and x < W and y<H and x+r <= W and y+r <= H :print("Yes")
else : print("No")

Submission status: Accepted

Solution code:
n = input().split()
W,H,x,y,r = map(int,n)
if x + r <= W and y + r <= H and x - r >= 0 and y - r >= 0:
    print("Yes")
else:
    print("No")