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:
A,V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
if A < B:
  if ((T*V+A) - (T*W+B) >=0):
    print("YES")
  else:
    print("NO")
else:
  if (((-T*V)-A) - ((-T*W)-B) >=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 A == B:
  print("YES")
  exit()

#逃げるほうが早い
if V <= W:
  print('NO')
  exit()
else:
  soutaikyori=abs(A-B)
  soutaiV=V-W
  #距離を詰めきれない
  if soutaikyori * soutaiV > T:
    print("NO")
    exit()
  else:
  #距離を詰めきれる
    #割り切れる
    """
    print("YES")
    exit()
    """
    if soutaikyori%soutaiV==0:
      print("YES")
    else:
      #割り切れない
      amari = soutaikyori % soutaiV
      keikazikan = soutaikyori / soutaiV
      nokorizikan = T - keikazikan
      if A > B:
        A += V * keikazikan
        B += W * keikazikan
      else:
        A -= V * keikazikan
        B -= W * keikazikan

      for t in range(nokorizikan):
        #Aは近づく，Bは離れる
        if A == B:
          print("YES")
          exit()
        elif A > B:
          A -= V
          B -= W
        else:
          A += V
          B += W
      
      print("NO")

Submission status: Wrong Answer

Solution code:
a, v = [int(i) for i in input().split()]
b, w = [int(i) for i in input().split()]
t = int(input())
s = "NO"
for i in range(t):
  if a+(v*(i+1)) == b+(w*(i+1)):
    s = "YES"
    break
print(s)

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:
  print('NO')

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

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:
    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())

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

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

Submission status: Wrong Answer

Solution code:
a, v = [int(s) for s in input().split(" ")]
b, w = [int(s) for s in input().split(" ")]
t = int(input())

if v == w:
  print("NO")
else:
  x = (b - a) // (v - w)
  if abs(b - a) % abs(v - w) != 0:
    print("NO")
  elif x <= t and x >= 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 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')
else:
  x=A-B
  y=W-V
  z=int(x//y)
  if x%y!=0:
    print('NO')
  else:
    if z<0:
      print('NO')
    else:
      if z<=T:
        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())
catch = False
for i in range(t+1):
    if a==b:
        catch=True
        break
    a += v
    b += w
if catch:
    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())

h=V-W
y=B-A

if h*T>=y:
    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:
  if ((T*V+A) - (T*W+B) >=0):
    print("YES")
  else:
    print("NO")
else:
  if (((-T*V)-A) - ((-T*W)-B) >=0):
    print(((-T*V)-A) - ((-T*W)-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 a == b:
    flag = True
else:
    flag = False

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

print("YES" if flag == True else "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")
elif v <= w:
    print("NO")
else:
    if (b-a)/(v-w) == int((b-a)/(v-w)) and abs((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())
x=a+(v*t)
y=b+(w*t)
if x>=y:
    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 >=0 and b>=0 :
    if a+v*t >= b+ w*t:
        print("YES")
    else:
        print("NO")
elif a <0 and b >=0:
    if -a+v*t >= b + w*t:
        print("YES")
    else :
        print("NO")
elif a > b:
    print("YES")
else :
    if -a+v*t >= -b+ w*t:
        print("YES")
    else:
        print("NO")

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

#逃げる方が大きかったら確実に捕まえられない
if W >= V:
    print("NO")
else:
    idouA = V * T
    idouB = W * T
    kankaku = abs(abs(A) - abs(B))
    if(idouB + kankaku <= idouA):
        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-1)) >= b+(w*(t-1)):
    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
    flag = False

    for i in range(T):
        L = L - v
        if L == 0:
            flag = True
            break
    if flag:
        print("YES")
    else:
        print("No")

Submission status: Wrong Answer

Solution code:
[A,V]=[int(i) for i in input().split()]
[B,W]=[int(i) for i in input().split()]
T=int(input())
if max(A-B,B-A)>T*max(V-W,W-V):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 <= B:
    if A + V * T >= B + W * T:
        print('YES')
    else:
        print('NO')
else:
    if V >= W:
        print('NO')
    elif 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())
D=abs(A-B)
S=V-W
if (S<=0):
    print("NO")
elif (D / S <= T) & (D % S == 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")
else:
  if b > a:
    if abs(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())
l = b-a
s = v-w
if s == 0:
  print('NO')
else:
  if 0<=l/s<=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())
gap_l = abs(A-V)
gap_v = W-V
if gap_v*T < gap_l:
    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<B and (V-W)*T>=B-A:
    print("Yes")
elif A>B and (V-W)*T>=A-B:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
a,v = input().split(' ')
b,w = input().split(' ')
T = int(input())
A = int(a)
V = int(v)
B = int(b)
W = int(w)

for t in range(T):
	if(abs(A-B)<abs(V*t-W*t)):
		print("YES")
		break
print("NO")

Submission status: Wrong Answer

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

la=a+v*t
lb=b+w*t

if la>=lb:
  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")
else:
    if((V-W)*T>abs(A-B)):
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
"""
~~ Author : Bhaskar
~~ Dated : 13~06~2020
"""

import sys
from bisect import *
from math import floor, sqrt, ceil, factorial as F, gcd, pi
from itertools import chain, combinations, permutations, accumulate
from collections import Counter, defaultdict, OrderedDict, deque

INT_MAX = sys.maxsize
INT_MIN = -(sys.maxsize) - 1
mod = 1000000007
ch = "abcdefghijklmnopqrstuvwxyz"
lcm = lambda a, b: (a * b) // gcd(a, b)
setbit = lambda x: bin(x)[2:].count("1")
INT = lambda type: type(sys.stdin.readline()) if type in [int, float] else type(sys.stdin.readline()).replace("\n", "")
ARRAY = lambda type: list(map(type, sys.stdin.readline().split()))
NUMS = lambda type: map(type, sys.stdin.readline().split())


def solve():
    a,v = NUMS(int)
    b,w = NUMS(int)
    t = INT(int)
    if v == w:
        if a == b:
            print("YES")
        else:
            print("NO")
    else:
        if max(v,w)%min(v,w) == 0 and max(v,w)//min(v,w) <= t:
            print("YES")
        else:
            print("NO")





if __name__ == "__main__":
    solve()

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:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
a,va = [int(i) for i in input().split()]
b,vb = [int(i) for i in input().split()]
c = int(input())

print ( "YES" if c*(va-vb)>= b-a else "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)*t>=(b-a):print("YES")
# else:print("NO")
for i in range(t+1):
	if a+(v*i)==b+(w*i):
		t=-1
		break
if t==-1:print("YES")
else:print("NO")

Submission status: Wrong Answer

Solution code:
A, W = map(int,input().split())
B, V = map(int,input().split())
T = int(input())
flag = "NO"
a = []
b = []
a.append(A)
b.append(B)
if A == B:
    flag = "YES"

for i in range(1, T+1, 1):
    a.append(W + a[i-1])
    b.append(V + b[i-1])
    if a[i] == b[i]:
        flag = "YES"
        break

print(flag)

Submission status: Wrong Answer

Solution code:
_input = input
'''
allinputs = iter(input().splitlines())
input = lambda : next(allinputs)
#'''

#ここに書きたいコードを書く
#データ読み込み
a,v=map(int, input().split())
b,w=map(int, input().split())
t=int(input())

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

input = _input

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 and A_ >= B_:
  print('YES')
elif A > B and 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())

diff = abs(a-b)
speed = v-w

if speed < 0:
  print('NO')
elif speed*t > diff:
  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())

kyori = max(A-B, B-A)

if W>V:
  print("NO")
else:
  if (W-V)*T>=kyori:
    print("YES")
  else:
    print("NO")

Submission status: Wrong Answer

Solution code:
line1 = input().split()
a = int(line1[0])
a_move = int(line1[1])

line2 = input().split()
b = int(line2[0])
b_move = int(line2[1])

time = int(input())

for count in range(time):
    a += a_move
    b += b_move
    if (a == b):
        print("YES")
        break
    elif (count == time - 1):
        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 v > w:
    if a+v*t >= b + w*t:
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
i=(input().split())
j=(input().split())
k=(input())

A=int(i[0])
V=int(i[1])
B=int(j[0])
W=int(j[1])
T=int(k)

if (B-A)+W*T <= 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())

s = abs(b-a)
y = (v-w)

if y <= 0:
    print('NO')
else:
    m = s % y
    u = s //y
    if m == 0:
        if u <= 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 + 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())

for i in range(1,t+1):
    if a+i*v==b+i*w:
        print("YES")
        break
else:
    print("NO")

Submission status: Wrong Answer

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

distance = abs(B - A)
hayasa = V - W

if distance == 0:
  print('YES')
elif hayasa > 0 and hayasa * T > distance:
  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())

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

if W>=V and A!=B:
    print('NO')
elif T*tiji < kyori:
    print('NO')
elif kyori % tiji ==0:
    print('YES')
else:
    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 v - w == 0:
  print('NO')
  exit()
if (b-a) / (v-w) % 1 == 0 and (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())

oni = A
human = B
for t in range(T):
    oni += V
    human += W
    if oni == human:
        print('YES')
        exit()
print('NO')


# if V * T + A >= W * T + 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 A > B:
  result = "YES"
elif A == B:
  result = "YES"
else:
  if V - W > 0:
    for i in range(1, T + 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())
T = int(input())
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())

if abs(B - A) > abs((V-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())


ag = a + v * t
bg = b + w * t

if b < a:
    print("NO")
    exit()

if ag >= bg:
    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')
else:
  x=A-B
  y=W-V
  z=int(x//y)
  if x%y!=0:
    print('NO')
  else:
    if z<0:
      print('NO')
    if 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秒以内
t=int(input())

if v==w:
    print("NO")
    exit()

from fractions import gcd
g=gcd(v,w)
v=v//g
w=w//g



if (b-a)/(v-w)<t*g and (b-a)/(v-w)>0:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
import decimal
d = decimal.Decimal('1.1')
a,v =map(decimal.Decimal,input().split())
b,w =map(decimal.Decimal,input().split())
t =decimal.Decimal(input())

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

Submission status: Wrong Answer

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

A = int(a[0])
V = int(a[1])

b = input().split()

B = int(b[0])
W = int(b[1])

T = int(input())

if A<B and A + V*T>= B +W*T:
    print("YES")
elif A>B and B +W*T>=A + 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())
x = abs(A - B)
v = V - W
if v <= 0:
        print('NO')
else:
    if T < x // v:        
        print('NO')
    elif x % v > 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())

if v <= w:
    print("NO")
elif int((v-w)/(b-a)) <= 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())

if (W-V) == 0:
    print("NO")
elif abs(B-A) % abs(W-V) != 0:
    print("NO")
else:
    if B > A:
        ans = (B-A)//(V-W)
        if 1 <= ans <= T:
            print("YES")
        else:
            print("NO")
    else:
        ans = (A-B)//(W-V)
        if 1 <= ans <= 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())
x1=(v-w)
y1=(b-a)
    
if(y1!=0 and x1%y1==0 and x1//y1>0):
    print('YES')
elif(y1==0 and x1==0):
    print('YES')
else:
    print("NO")

Submission status: Wrong Answer

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

A = int(A)
V = int(V)
B = int(B)
W = int(W)
T = int(T)

result = (B - A) + (W * T) - V * T

if result <= 0:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
A, V = map(int, input().rstrip().split())
B, W = map(int, input().rstrip().split())
T = int(input().rstrip())
d = abs(A-B)
v = V-W
if v <= 0:
    print('NO')
elif d % v != 0:
    print('NO')
elif T < d / v:
    print('NO')
else:
    print('YES')

Submission status: Wrong Answer

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

A_sum = A + V * T
B_sum = B + W * T

if A_sum >= B_sum:
    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 (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())

for i in range(1,t+1):
    if a+(v*i)>=b+(w*i):
        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())
# print(a,v)
# print(b,w)
# print(t)

dl = abs(a-b)
dv = w-v
# print(dl,dv)
if dv < 0:
    # print(dl//dv)
    # if (dl+dv-1)//abs(dv) <= t:
    if dl//abs(dv) <= t:
        print('YES')
    else:
        print('NO')
else:
    if dl == 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 W==V:
    print("NO")
else:
    tmp = (B-A)/(V-W)
    if tmp >= 0 and tmp%1==0 and tmp <= 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:
  x = b-a
else:
  x = a-b
  y = (v-w)*t
  if y>=x:
    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:
  print("YES")
else:
  print("NO")

Submission status: Wrong Answer

Solution code:
#デフォルト
import itertools
from collections import defaultdict
import collections
import math
import sys
sys.setrecursionlimit(200000)
mod = 1000000007

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

sub = abs(b - a)
if sub == 0:
    print("YES")
else:
    ss = v - w
    if ss < 1:
        print("NO")
    else:
        if ss == 1:
            if sub / ss <= t:
                print("YES")
            else:
                print("NO")
        elif sub % 2 == 0 and ss % 2 == 0:
            if sub / ss <= t:
                print("YES")
            else:
                print("NO")
        elif sub % 2 == 1 and ss % 2 == 1:
            if sub / ss <= 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())

ans = "NO"

if(A<B):
    if(A/T+V > B/T+W):
        ans = "YES"
elif(A>B):
    if(A/T+(-1)*V < B/T+(-1)*W):
        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())

    if v == w:
        print('NO')
        return 0
    if b-a > 0 and w-v > 0:
        print('NO')
        return 0
    if 0 <= (b-a)/(v-w) <= t:
        print('YES')
    else:
        print('NO')

if __name__ == '__main__':
    main()

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]

for i in range(T):
    if A <= B:
        B += W
        A += V
    else:
        B -= W
        A -= V

if abs(A) >= abs(B):
    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 and T > (abs(A - B) / abs(V - W)):
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

Solution code:
import re
import sys
from bisect import bisect, bisect_left, insort, insort_left
from collections import Counter, defaultdict, deque
from copy import deepcopy
from decimal import Decimal
from itertools import (
    accumulate, combinations, combinations_with_replacement, groupby,
    permutations, product)
from math import (acos, asin, atan, ceil, cos, degrees, factorial, gcd, hypot,
                  log2, pi, radians, sin, sqrt, tan)
from operator import itemgetter, mul
from string import ascii_lowercase, ascii_uppercase, digits


def inp():
    return(int(input()))


def inlist():
    return(list(map(int, input().split())))


def instr():
    s = input()
    return(list(s[:len(s)]))


def invr():
    return(map(int, input().split()))


a, v = invr()
b, w = invr()
t = inp()
res = "NO"
for i in range(t+1):
    s1 = 0
    s2 = 0
    if b < a:
        s1 = a - v*i
    else:
        s1 = a + v * i

    if b < 0:
        s2 = b - w * i
    else:
        s2 = b + w * i

    if s1 == s2:
        res = "YES"
print(res)

Submission status: Wrong Answer

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

if a < 0:
    if b < 0:
        ab = -b - -a
    else:
        ab = -a + b
else:
    ab = b - a

vt = v * t
wt = w * t



if vt - wt >= ab:
    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 and v >= w:
    print("NO")
    exit(0)
elif a < b and v <= w:
    print("NO")
    exit(0)


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

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 !=0 and 0<D/(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())

count = 0
a = A
b = B

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

if V <= W:
  print("NO")
else:
  sa = B - A
  diff = V - W
  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 b > a:
    if abs(w*t+b)-abs(v*t+a) >=0:
        print("NO")
    else:
        print("YES")
else:
    if abs(-w*t-b) - abs(-v*t-a) >=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())

x=b-a
y=v-w

if y*t>=x:
    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())
flg = True

if v <= w:
  flg = False
else:
  if a < b:
    if (b - a) / (v - w) == int((b - a) / (v - w)) and (b - a) / (v - w) <= t:
      flg = True
    else:
      flg = False
  else:
    if (a - b) / (v - w) == int((a - b) / (v - w)) and (a - b) / (v - w) <= t:
      flg = True
    else:
      flg = False
print("YES" if flg else "NO")

Submission status: Wrong Answer

Solution code:
from sys import exit
import math
ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))

a,v = mi()
b,w = mi()
t = ii()

dis = abs(a-b)

if v<=w:
    print("NO")
    exit()

if dis <= abs(v-w)*t and dis%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())
if B > A :
    if A + V*T >= B + W*T :
        print('Yes')
    else :
        print('No')
elif A > B :
    if B - W*T >= A - 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())

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

if W>=V and A!=B:
    print('NO')
elif A==B:
    print('YES')
elif T*tiji < kyori:
    print('NO')
elif kyori % tiji ==0:
    print('YES')
else:
    print('NO')

Submission status: Wrong Answer

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

print('YES' if np.log(a+v*t) >= np.log(b+w*t) else 'NO')

Submission status: Wrong Answer

Solution code:
A_V = input().split()
A = int(A_V[0])
V = int(A_V[1])
B_W = input().split()
B = int(B_W[0])
W = int(B_W[1])
T = int(input())

if abs(B-A) < (V-W)*T:
    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())

for i in range(t):
    if a+v*i >= b+w*i and a<b or a+v*i <= b+w*i and a>b:
        print("YES")
        break
print("NO")

Submission status: Wrong Answer

Solution code:
A,V=map(int,input().split())
B,W=map(int,input().split())
T=input()
if ((V-W)*int(T)) <= abs(A-B):
    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())

x = A + V * T
y = B + W * T

if A < B:
  if x >= y:
    print('YES')
  else:
    print('NO')
else:
  if x > y:
    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())

a_2 = t * v + a
b_2 = t * w + b

if a_2 >= b_2:
    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())
ans=0
for i in range(1,t+1):
  if a + v * i == b + w * i:
    ans='YES'
    break
  else:
    ans='NO'
print(ans)

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 (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())
if a<b:
    if a+v*t>=b+w*t:
        print('YES')
    else:
        print('NO')
else:
    if b-w*t<=a-v*t:
        print('YES')
    else:
        print('NO')

Submission status: Wrong Answer

Solution code:
A, V = list(map(int, input().split()))  # 入力のときに N を使う必要はありません
B, W = list(map(int, input().split()))  # 入力のときに N を使う必要はありません
T = int(input())  # 入力のときに N を使う必要はありません

if A - B > 0:
    V = -V
    W = -W
elif A - B == 0:
    print("YES")

else:
    if (A + V*T) - (B + 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 a >=0 and b>=0 :
    if a+v*t >= b+ w*t:
        print("YES")
    else:
        print("NO")
elif a <0 and b >=0:
    if -a+v*t >= b + w*t:
        print("YES")
    else :
        print("NO")
else :
    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())

av = a + (v*t)
bw = b + (w*t)

if av > bw:
  print('YES')
else:
  print('NO')