Problem:


Score : 200 points

Problem Statement

Two children are playing tag on a number line. (In the game of tag, the child called "it" tries to catch the other child.) The child who is "it" is now at coordinate A, and he can travel the distance of V per second.
The other child is now at coordinate B, and she can travel the distance of W per second.

He can catch her when his coordinate is the same as hers.
Determine whether he can catch her within T seconds (including exactly T seconds later).
We assume that both children move optimally.

Constraints

-10^9 \leq A,B \leq 10^9

1 \leq V,W \leq 10^9

1 \leq  T \leq 10^9

A \neq B

All values in input are integers.

Input

Input is given from Standard Input in the following format:

A V
B W
T

Output

If "it" can catch the other child, print YES; otherwise, print NO.

Sample Input 1

1 2
3 1
3

Sample Output 1

YES

Sample Input 2

1 2
3 2
3

Sample Output 2

NO

Sample Input 3

1 2
3 3
3

Sample Output 3

NO



Sample input:
1 2
3 1
3


Sample output:
YES

Submission status: Wrong Answer

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

def main():
    A, V = map(int, readline().split())
    B, W = map(int, readline().split())
    T = int(input())

    for _ in range(T):
        if A == B or A >= B:
            print('YES')
            return
        else:
            A += V
            B += W
    print('NO')
    
main()

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
if B==A:
  print("YES")
elif W >= V or B<A or B-A>(V-W)*T:
  print("NO")
else:
  print("YES")

Submission status: Wrong Answer

Solution code:
#2問目
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
idouA = 0
idouB = 0
kankaku = 0

#逃げる方が大きかったら確実に捕まえられない
if W >= V:
    print("NO")
else:
    idouA = V * T
    idouB = W * T
    if A < B:
        if A < 0 and B < 0:
            kankaku = abs(A) - abs(B)
        elif A > 0 and B > 0:
            kankaku = abs(B) - abs(A)
        elif A < 0 and B > 0:
            kankaku = B - A
    elif B < A:
        if A < 0 and B < 0:
            kankaku = abs(B) - abs(A)
        elif A > 0 and B > 0:
            kankaku = abs(A) - abs(B)
        elif A > 0 and B < 0:
            kankaku = A - B
            
    if(idouB + kankaku <= idouA):
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
# スペース区切りの整数の入力
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
# 文字列の入力
#s = input()
#開業されたN個要素を受け付ける
#input_list = [list(map(int, input().split())) for i in range(N)]

#print()

ans = "NO"
t=0

if W<V:
    if abs(A-B) % (V-W) == 0:
        if (abs(A-B) / (V-W)) <= T:
            ans = "YES"



print(ans)

Submission status: Wrong Answer

Solution code:
a,v = map(int, input().split())
b,w = map(int, input().split())
t = int(input())
c=0
for i in range(1,t+1):
    if a<b:
        newa = a + v*i
        newb = b + w*i
    elif a > b:
        newa = a - v*i
        newb = b - w*i
    if newa ==newb:
        c+=1
    
if c >0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
L = 10**9
if A < B:
    A += V*T
    B += W*T
    print("YES" if A >= B or B > L else "NO")
else:
    A -= V*T
    B -= W*T
    print("YES" if A <= B or B < 0 else "NO")

Submission status: Wrong Answer

Solution code:
A = list(map(int, input().split()))
B = list(map(int, input().split()))
T = int(input())

if (B[1]-A[1])>=0:
    print('NO')
elif abs(A[0]-B[0])<abs(T*(A[1]-B[1])) and abs(A[0]-B[0])%abs(A[1]-B[1])==0:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
A, V = [ int(i) for i in input().strip().split(' ')]
B, W = [ int(i) for i in input().strip().split(' ')]
T = int(input())

# 鬼が右
if A > B:
    A_len = max(-(10**9), A-V*T)
    B_len = max(-(10**9), B-W*T)
    if A_len <= B_len:
        print('YES')
    else:
        print('NO')
# 鬼が左
else:
    A_len = min(10**9, A+V*T)
    B_len = min(10**9, B+W*T)
    if A_len >= B_len:
        print('YES')
    else:
        print('NO')

Submission status: Wrong Answer

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

if(int(b[1])>=int(a[1])):
	print("NO")
else:
	length = int(a[0]) - int(b[0])
	v = int(a[1]) - int(b[1])
	times = length / v
	if(times <= int(c)):
		print("YES")
	else:
		print("NO")

Submission status: Wrong Answer

Solution code:
import sys

pos_a, vel_a = map(lambda x: int(x), input().split())
pos_b, vel_b = map(lambda x: int(x), input().split())
t = int(input())
 
# 鬼の方が遅い
if vel_a <= vel_b:
  print('NO')
  sys.exit()
  
if abs(pos_a - pos_b) / vel_a - vel_b > t:
  print('NO')
  sys.exit()
  
print('YES')

Submission status: Wrong Answer

Solution code:
a, v = list(map(int, input().split()))
b, w = list(map(int, input().split()))
t = int(input())

if a == b:
    print('NO')
    exit()

elif b > a:
    if v <= w:
        print('NO')
        exit()
    if b - a <= t * (v-w):
        print('YES')
        exit()
    else:
        print('NO')
        exit()
else:
    if w <= v:
        print('NO')
        exit()

    if a - b <= t * (w-v):
        print('NO')
        exit()
    else:
        print('NO')
        exit()

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
c,d=map(int,input().split())
e=int(input())
if  abs(a)+b*e>=abs(c)+d*e :
  print('YES')  
else:
  print('NO')

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
c,d = map(int,input().split())
e = int(input())

f = a + (b*e)
g = c + (d*e)

if f > g:
	print("YES")
else:
	print("NO")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())


if a + v * t >= b + w * t:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
a, b= map(int,input().split(' '))
c,d=map(int,input().split(' '))
e=int(input())

if (a+(b*e))>=(c+(d*e)):
    print('YES')
if (a+(b*e))<=(c+(d*e)):
    print('NO')

Submission status: Wrong Answer

Solution code:
A, V=map(int,input().split())
B, W=map(int,input().split())
T =int(input())
D = abs(A-B)

if 10**9-A<=V*T and A<B:
  print("YES")
elif abs(-10**9-A)<=V*T and A>B:
  print("YES")
elif (V-W)*T>=D:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())
flag=0
if v<=w:
    pass
elif a==b:
    flag=1
elif (b-a)>0:
    pass
elif ((b-a)/(v-w))<=t:
    flag=1
if flag==1:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
A, V = list(map(int, input().split()))
B, W = list(map(int, input().split()))
T = int(input())

if V == W:
    print("NO")
    exit()

for t in range(T):
    if A + V * t >= B + W * t:
        print("YES")
        exit()
print("NO")

Submission status: Wrong Answer

Solution code:
import sys
import math
import itertools
import collections
import heapq
import re
import numpy as np

rr = lambda: sys.stdin.readline().rstrip()
rs = lambda: sys.stdin.buffer.readline().split()
ri = lambda: int(sys.stdin.readline())
rm = lambda: map(int, sys.stdin.buffer.readline().split())
rl = lambda: list(map(int, sys.stdin.readline().split()))
inf = float('inf')
mod = 10**9 + 7

a, v = rm()
b, w = rm()
t = ri()
if a < b:
  if a + (v-w)*t >= b + (v-w)*t:
    print('YES')
  else:
    print('NO')
else:
  print('NO')

Submission status: Wrong Answer

Solution code:

a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())

flag=False

for i in range(t+1):
    if a+v*i==b+w*i:
        flag=True
        break
    else:
        continue

print('YES' if flag else 'NO')

Submission status: Wrong Answer

Solution code:
a, v = map(int,input().split())
b, w = map(int,input().split())
T = int(input())

A = a + v * T
B = b + w * T

if A>= B:
    print("Yes")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
def solve():
    a, v = map(int, input().split())
    b, w = map(int, input().split())
    t = int(input())

    if (v-w) > 0:
        x = (b-a)//(v-w)
    else:
        return 'NO'
        
    if x*v + a == x*w + b:
        return 'YES'

    return 'NO'


print(solve())

Submission status: Wrong Answer

Solution code:
a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())
y1=(v-w)
x1=(b-a)
if(x1==0):
    f=1
elif(y1==0):
    f=0
elif(x1%y1==0):
    x=x1//y1
    if 0<=x<=t:
        f=1
    else:
        f=0
else:
    f=0
if(f==1):
    print('YES')
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())


for i in range(T+1):
    if A == B:
        print("YES")
        exit()
        if A < B:
            A = A + V * i
            B = B + W * i
        else:
            A = A - V * i
            B = B - W * i 

print("NO")

Submission status: Wrong Answer

Solution code:
#Problem No.B

A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

dis = abs(A-B)
mob = W-V
now = dis
a = [dis]
for i in range(T):
    now += mob
    a.append(now)

if 0 in a:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split(' '))
b, w = map(int, input().split(' '))
t = int(input())
r = 'NO'
if  b - a <= abs(w * t - v * t):
    r = 'YES'
print(r)

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
if A > B:
  result = "YES"
elif A == B:
  result = "YES"
else:
  if V - W > 0:
    if B - A - T * (V - W) > 0:
      result = "NO"
    else:
      for i in range(T + 1, 1, -1):
        if B - A - i * (V - W) == 0:
          result = "YES"
          break
        else:
          result = "NO"
  else:
    result = "NO"
print(result)

Submission status: Wrong Answer

Solution code:
A, V = map(int,input().split())
B, W = map(int,input().split())

a = A
b = B
T = int(input())

if a < b:
    a += V * T
    b += W * T

    print('NO')
else:
    print('YES')

Submission status: Wrong Answer

Solution code:
a,v = map(int, input().split())
b,w = map(int, input().split())
t = int(input())
d = abs(a-b)
s = v - w
if s > 0 and not d%s and d/s <= t:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a, v = [int(a) for a in input().split()]
b, w = [int(a) for a in input().split()]
t = int(input())
ret = w-v
ans = ""
if (ret*t)  <= (b-a):
  ans = "NO"
else:
  ans =  "YES"
print(ans)

Submission status: Wrong Answer

Solution code:
def main():
  a, v = map(int,input().split())
  b, w = map(int,input().split())
  t = int(input())
  ans = True

  a_can_plus = min(a + v * t, 10 ** 9)
  a_can_minus = max(a - v * t, -10 ** 9)
  b_can_plus = min(b + w * t, 10 ** 9)
  b_can_minus = max(b - w * t, -10 ** 9)

  if v - w < 0: 
    ans  = False
  elif a > b:
    if b_can_minus < a_can_minus:
      ans = False
    else:
      ans = True  
  elif a < b:
    if a_can_plus < b_can_plus:
      ans = False
    else:
      ans = True
      
  if ans:
    print("YES")
  else:
    print("NO")            


main()

Submission status: Wrong Answer

Solution code:
def solve():
	posA, speedA = map(int, input().split())
	posB, speedB = map(int, input().split())
	T = int(input())
	low, high = 1, T
	while low <= high:
		mid = low + (high - low) // 2
		if posA + speedA * mid == posB + speedB * mid:
			return "YES"
		elif posA + speedA * mid < posB + speedB * mid:
			low = mid + 1
		else:
			high = mid - 1
	return "NO"




def main():
	print(solve())


if __name__ == '__main__':
	main()

Submission status: Wrong Answer

Solution code:
A, V = list(map(int, input().split()))
B, W = list(map(int, input().split()))
T = int(input())

sub_BA = B-A
sub_WV = W-V

if sub_WV == 0:
  print("NO")
elif (sub_BA * sub_WV) < 0 and sub_BA % sub_WV == 0:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())

for _ in range(t):
    if abs(a + v - b) <= abs(a - v - b):
        ar = a + v
    else:
        ar = a - v

    if abs(b + w - a) >= abs(b - w - a):
        br = b + w
    else:
        br = b - w

    if ar == br:
        print("YES")
        exit()
    else:
        a = ar
        b = br

print("NO")

Submission status: Wrong Answer

Solution code:
a,v = map(int,input().split())
b,w = map(int,input().split())
t = int(input())
flg = 0

for _ in range(t):
    if a < b:
        if v <= w:
            break
        if a+v >= b+w:
            flg = 1
            break
        a = a+v
        b= b+w
    else:
        if v >= w:
            break
        if a-v <= b-w:
            flg = 1
            break
        a = a-v
        b=b-w
        
if flg == 0:
    print("NO")
else:
    print("YES")

Submission status: Wrong Answer

Solution code:
a,v = map(int, input().split())
b,w = map(int, input().split())
t = int(input())

oni = v*t + a
nige = w*t +b

if b > a:
    if oni >= nige:
        print("YES")
    else:
        print("NO")
else:
    if oni <= nige:
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
#DEMON# 
RD, SD = map(int, input().split())
#CRIMINAL#
RC, SC = map(int, input().split())

T = int(input())

for i in range(T):
  RD += SD
  RC += SC
  
if RD >= RC:
  print("NO")
  
else:
  print("YES")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
distance = v-w
dist = a-b
if distance == 0:
    print('NO')
elif a<b and v<w:
    print('NO')

elif dist%distance == 0 and abs(dist//distance)<= t :
    print('YES')
    
else :
    print('NO')

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())

iter = False
for t_a in range(t+1):
  for t_b in range(t+1):
    if a + t_a*v - (t-t_a)*v == b + t_b*w - (t-t_b)*w:
      iter = True
      break

if iter == False:
  print("NO")
else:
  print("YES")

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
if A + (V*T) >= B + (W*T):
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
def onigokko(A, V, B, W, T):
    if B >= A :
        if (B + W*T)-(A + V*T) <=0:
            return "Yes"
        else:
            return "No"
    else:
        if (B - W*T)-(A - V*T) >=0:
            return "Yes"
        else:
            return "No"
print(onigokko(1,2,3,1,3))
print(onigokko(1,2,3,2,3))

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
c,d = map(int,input().split())
e = int(input())

f = int(a + (b*e))
g = int(c + (d*e))

if f >= g:
	print("YES")
else:
	print("NO")

Submission status: Wrong Answer

Solution code:
a,v=(int(x) for x in input().split())
b,w=(int(x) for x in input().split())
t = int(input())

flag = 0
if v > w and a<b:
    for i in range(t):
        if a+v*i >= b+w*i:
            flag = 1
            break
elif a == b:
    flag = 1

if flag ==1:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())

if (b-a)<= (v-w)*t:
    print ("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
A,V=map(int,input().split())
B,W=map(int,input().split())
T=int(input())

eva=False

pl=abs(B-A)
ve=V-W

print(pl)
print(ve)

if pl<=ve*T:
    if ve>0:
        eva=True
if eva:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())


cnt = 0
for tt in range(t):
    a_dist = v * tt + a
    b_dist = w * tt + b
    if a>b or w>v:
        break
    res = b_dist - a_dist
    if res == 0:
        cnt = 1
        break

if cnt == 1:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
a, v = list(map(int, input().split()))
b, w = list(map(int, input().split()))
t = int(input())

if v - w != 0:
  dt = (b - a) // (v - w)
  waru = (b - a) % (v - w)

  flag = False
  if (0 < dt and t >= dt) and waru == 0:
    flag = True
    
  print("YES" if flag else "NO")
  
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())
if abs(b-a)/t<v-w:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:

A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

count = 0
a = A
b = B

if A == B:
  print("NO")
  exit()

if A < B:
  if V <= W:
    print("NO")
  else:
    if A+T*V >= 1000000000 and B+T*W >= 1000000000:
      print("YES")
      exit()

    sa = B - A
    diff = V - W
    if sa % diff == 0:
      if sa//diff <= T:
        print(sa//diff)
        print("YES")
      else:
        print("NO")
    else:
      print("NO")
else:
  if V >= W:
    print("NO")
  else:
    sa = A - B
    diff = W - V
    if sa % diff == 0:
      if sa//diff <= T:
        print("YES")
      else:
        print("NO")
    else:
      print("NO")

Submission status: Wrong Answer

Solution code:
A,V = map(int,input().split(' '))
B,W = map(int,input().split(' '))
T = int(input())
if A <= B :
    print('YES' if T*V+A >= T*W+B else 'NO')
else:
    print('NO' if T*V+A >= T*W+B else 'YES')

Submission status: Wrong Answer

Solution code:
a,v = input().split()
b,w = input().split()
t = input()

move_a = int(v) * int(t) + int(a)
move_b = int(w) * int(t) + int(b)

if int(a) == int(b):
	a,v = input().split()
	b,w = input().split()
	t = input()
else:
    if move_a >= move_b:
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
import decimal
import sys

a,v =map(decimal.Decimal,input().split())
b,w =map(decimal.Decimal,input().split())
t =decimal.Decimal(input())

if a==b:
    print('YES')
    sys.exit()
if (a+v*t)>=(b+w*t):
    print('YES')
    sys.exit()
else:
    print('NO')
    sys.exit()
if (a+v*t)<=(b+w*t):
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())

flag=True
if v<=w:
    print('NO')
elif (a+v*t)>=(b+w*t) and abs(a-b)%abs(v-w)==0:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
A,V = map(int, input().split())

B,W = map(int, input().split())

T=int(input())

kyori=abs(B-A)
idousa=V-W

if idousa>0:
  if T>=round(kyori/idousa, 1):
    print("YES")
  else:
    print("NO")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b,w = map(int, input().split())
t = int(input())

def run(x, y):
    global a
    global b

    if x > y:
        x -= v
        y -= w
    elif x < y:
        x += v
        y += w
    else:
        print('YES')
        exit()
    
    a = x
    b = y

for i in range(t):
    run(a,b)

print('NO')

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

dis = abs(max(A,B) - min(A,B))
velo = V - W
if velo <= 0:
    print('NO')
    exit()

if (dis/velo) < T:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
ai, am = map(int, input().split())
bi, bm = map(int, input().split())
tim = int(input())

if am-bm != 0:
    syo, jyoyo = divmod(bi-ai, am-bm)

    if jyoyo == 0 and 0 <= syo <= tim:
        print("YES")
    else:
        print("NO")

else:
    print("NO")

Submission status: Wrong Answer

Solution code:
from decimal import Decimal
a,v=map(int,input().split())
b,w=map(int,input().split())
t=int(input())

if a==b:
    print("YES")
    exit()
elif v==w:
    print("NO")
    exit()
a=abs(b-a)%abs(v-w)
atai = Decimal(str(a))
if atai==0:
    for i in range(1,t+1):
        if i == Decimal(abs(b-a))/Decimal(abs(v-w)):
            print("YES")
            exit()
    print("NO")

Submission status: Wrong Answer

Solution code:
A,V = map(int,input().split())
B,W = map(int,input().split())

T = int(input())

flag = True
if abs(A) < abs(B) and abs(V) < abs(W):
  flag = False


  

if flag:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

if W==V:
    print("NO")
else:
    tmp = (B-A)/(V-W)
    if 0 <= tmp and tmp <= T:
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
def main():
    a,v = map(int,input().split())
    b,w = map(int,input().split())
    t = int(input())

    a += 10**9
    b += 10**9
    if v == w:
        print('NO')
        return 0
    if a > b:
        print('NO')
    elif 0 <= (b-a)/(v-w) <= t:
        print('YES')
    else:
        print('NO')

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
A,V = map(int, input().split())
B,W = map(int, input().split())
T = int(input())

val1 = A-B
val2 = V-W

if val1 < 0 and val2 <= 0:
    print('NO')
    exit()
if val2 == 0 and val1 == 0:
    print('YES')
    exit()
elif val2 == 0 and val1 != 0:
    print('NO')
    exit()
if val1%val2 == 0 and abs(val1//val2) <= T:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())

if v > w:
    if abs(a-b)//(v-w) <= t:
        print("YES")
    else:
        print("NO")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
A,V=map(int, input().split())
B,W=map(int, input().split())
T=int(input())

if B<A and A-V*T<B-W*T:
  print("YES")
if  A+V*T>=B+W*T:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a,v = map(int,input().split())
b,w = map(int,input().split())
t = int(input())
if v < w:
    print('NO')
    exit()

if abs(abs(a)-abs(b)) < (v-w)*t:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
if __name__ == '__main__':
    A, V = map(int, input().strip().split(" "))
    B, W = map(int, input().strip().split(" "))
    T = int(input().strip())

    L = abs(A-B)
    v = V-W

    if L <= v * T:
        print('YES')
    else:
        print('No')

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

if A-B + (V-W)*T >= 0:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

if V == W:
  print('NO')
  exit()

if (B-A) % abs(V-W) == 0 and V > W:
  print('YES')
else:
  print('NO')

Submission status: Wrong Answer

Solution code:
A,V=map(int, input().split())
B,W=map(int, input().split())
T=int(input())

if W>=V:
    print('NO')
    exit(0)

if A*B<0:
    if (abs(A)+abs(B))//(V-W)<=T:
        print('YES')
    else:
        print('NO')
elif A*B>0:
    if abs(abs(A)-abs(B))//(V-W)<=T:
        print('YES')
    else:
        print('NO')
else:
    if abs(A-B)//(V-W)<=T:
        print('YES')
    else:
        print('NO')

Submission status: Wrong Answer

Solution code:
import sys
s = sys.stdin.readlines
A, V = [int(x) for x in input().split()]
B, W= [int(x) for x in input().split()]
T = int(input())

def f(A,V,B,W):
    if V == W:
        return 'NO'
    g = abs(A - B)
    for _ in range(T):
        A += V
        B += W
        if A == B:
            return 'YES'
        if abs(A - B) > g:
            return 'NO'
print(f(A, V, B, W))

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
if A == B:
    print("YES")
    exit()
if W >= V:
    print("NO")
else:
    C = abs(A - B)
    X = V - W
    if C // X > T:
        print("NO")
    else:
        print("YES")

Submission status: Wrong Answer

Solution code:
#数値型を分割して取り出し
A, V = map(int, input().split())
B, W = map(int, input().split())
#数値型の取り出し
T = int(input())
#初期値に時間を足す
AA = A
BB = B
ans = "NO"
for i in range(1,T+1):
  print(i)
  AA = AA + V
  BB = BB + W
  if AA == BB:
    ans = "YES"
    break
print(ans)

Submission status: Wrong Answer

Solution code:
a, v= map(int, input().split())
b, w= map(int, input().split())
t = int(input())
l = b-a
s = v-w
if s != 0:
    z = l/s
else:
    z = -1
if 0< z <= t:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())

if (a*b) >= 1:
    child = abs(b-a)
else:
    child = abs(a+b)

try:
    n = child/abs(v-w)
except ZeroDivisionError:
    n = -1
if n>=0 and n <= t:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
import sys

pos_a, vel_a = map(lambda x: int(x), input().split())
pos_b, vel_b = map(lambda x: int(x), input().split())
t = int(input())
 
# 鬼の方が遅い
if vel_a <= vel_b:
  print('No')
  sys.exit()
  
if abs(pos_a - pos_b) / vel_a - vel_b > t:
  print('No')
  sys.exit()
  
print('Yes')

Submission status: Wrong Answer

Solution code:
a,v = map(int,input().split())
b, w= map(int,input().split())
t = int(input())
A = a+(t*v)
B = b+(t*w)
if a == b:
    print('YES')
elif a < b:
    if B < A:
        print('YES')
    else:
        print('NO')
else:
    A = a-(t*v)
    B = b-(t*w)
    if A <= B:
        print('YES')
    else:
        print('NO')

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

if(V <= W):
	print("NO")
elif(abs(B - A) >= V * T):
	print("NO")
else:
	print("YES")

Submission status: Wrong Answer

Solution code:
import sys

a,v=map(int, input().split())
b,w=map(int, input().split())
t=int(input())
if b > a:
    dif = b - a
    if v <= w:
        print("NO")
        sys.exit(0)
    nowdif = v - w
elif b < a:
    dif = a - b
    if v >= w:
        print("NO")
        sys.exit(0)
    nowdif = w - v

if dif <= nowdif * t:
    print("YES")
    sys.exit(0)

print("NO")

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())

if v > w:
    if abs(a-b)//(v-w) <= t:
        print("YES")
    else:
        print("No")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
import sys
def input(): return sys.stdin.readline().rstrip()

def main():
    A, V = map(int, input().split())
    B, W = map(int, input().split())
    T = int(input())

    if W >= V:
        print('NO')
    elif (A - B) % (W - V) == 0 and abs((A - B) // (W - V)) <= T:
        print('YES')
    else:
        print('NO')

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
if v <= w:
  print('No')
  exit(0)

if abs(a-b)%(v-w) == 0:
  f = abs(a-b)//(v-w)
  if f <= t:
    print('Yes')
    exit(0)
print('No')

Submission status: Wrong Answer

Solution code:
import math

A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

MAX = 10**9
MIN = -(10**9)

if A >= B:
    A_after_T = max(MIN, A-V*T)
    B_after_T = max(MIN, B-W*T)
    # print("A_after_T: {}, B_after_T: {}".format(A_after_T, B_after_T))
    if A_after_T <= B_after_T:
        print("YES")
    else:
        print("NO")
else:
    A_after_T = min(MAX, A+V*T)
    B_after_T = min(MAX, B+W*T)
    # print("A_after_T: {}, B_after_T: {}".format(A_after_T, B_after_T))
    if A_after_T >= B_after_T:
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
import math
A, V = map(int, input().split())  
B, W = map(int, input().split())  
T=int(input())
if  B>A:
    kyo=B-A
if A>B:
    kyo=A-B

sub=V-W
wari=T+10
if sub!=0 and sub>0:
    wari=math.ceil(kyo//sub)
if wari<=T:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
AV = list(map(int,input().split()))
BW = list(map(int,input().split()))
T = int(input())

A = AV[0]
V = AV[1]
B = BW[0]
W = BW[1]

pos_A = A
pos_B = B

if A <= B:
    pos_B = B + T*W
    pos_A = A + T*V
else:
    pos_B = B - T*W
    pos_A = A - T*V


if abs(pos_A) >= abs(pos_B):
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
A,V = map(int,input().split())
B,W = map(int, input().split())
T = int(input())
if V*T+A >= W*T+B:
    if A>B:
        print('NO')
    else:
        print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
a, v = list(map(int, input().split(' ')))
b, w = list(map(int, input().split(' ')))
t = int(input())

if a > b:
    print('NO')
    exit()

if w >= v:
    print('NO')
    exit()

catchup_speed = (v - w) // 10 ** 10
start_dis = (b - a) // 10 ** 10

if start_dis <= t*catchup_speed:
    print('YES')
    exit()

print('NO')

Submission status: Wrong Answer

Solution code:
a, v = list(map(int, input().split()))
b, w = list(map(int, input().split()))
t = int(input())

if a == b:
    print('NO')
    exit()

elif b > a:
    if v <= w:
        print('NO')
        exit()
    if b - a <= t * (v-w):
        print('YES')
        exit()
    else:
        print('NO')
        exit()
else:
    if w <= v:
        print('NO')
        exit()

    if a - b <= t * (w-v):
        print('YES')
        exit()
    else:
        print('NO')
        exit()

Submission status: Wrong Answer

Solution code:
A , V = map(int,input().split())
B , W = map(int,input().split())
T = int(input())

ans ='NO'
if V > W  and abs(B-A)%(V-W) ==0:
    t = abs(B-A)//(V-W)
    if t <= T:
        ans = 'YES'


print(ans)

Submission status: Wrong Answer

Solution code:

a_par = list(map(int, input().rsplit())) 
b_par = list(map(int, input().rsplit()))
sec = int(input())

if a_par[0] + a_par[1] * sec >= b_par[0] + b_par[1] * sec:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
A, V = [int(n) for n in input().split()]
B, W = [int(n) for n in input().split()]
T = int(input())

if V == W:
    print('NO')
    exit()

if B > A:
    for t in range(1, T+1):
        if B+W*t == A+V*t:
            print('YES')
            exit()
else:
    for t in range(1, T+1):
        if B-W*t == A-V*t:
            print('YES')
            exit()
print('NO')

Submission status: Wrong Answer

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

a, v = map(int, input().split())
b, w = map(int, input().split())
T = int(input())

k = b - a
l = T*v - T*w 

flag = False

if (k <= l):
    flag = True

if (flag == True):
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
import sys

A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())

for i in range(T):
    A = A + V
    B = B + W
    if A == B:
        print('YES')
        sys.exit()
    elif A > B:
        A, B = B, A
print('NO')

Submission status: Wrong Answer

Solution code:
def onigokko(A, V, B, W, T):
    if B >= A :
        if (B + W*T)-(A + V*T) <=0:
            return "Yes"
        else:
            return "No"
    else:
        if (B - W*T)-(A - V*T) >=0:
            return "Yes"
        else:
            return "No"

Submission status: Wrong Answer

Solution code:
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())

if a+v*t >= b+w*t and a < b:
  if (b-a)%(abs(v-w))==0:
    print("YES")
  else:
    print("NO")
else:
  print("NO")