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 numpy as np
import sys
#import copy


def xnxn(n=0, flag="v"):
    """
    args:
        int n: a number of lows to read
    example:
        input   1
        retrun  1

        input   1 2 3
        return  [1,2,3]
        input   1 2 3
                4 
        return  [[1,2,3],
                [4]]
    """
    if n == 0:
        temp = list(map(int, input().split()))
        if len(temp) == 1:
            if flag == "l":
                return temp
            else:
                return temp[0]
        elif len(temp) > 1:
            return temp
    else:
        temp = [list(map(int, input().split())) for _ in range(n)]
        return temp


def sp_xnxn(n=0):
    """
    args:
        int n: a number of lows to read
    example
        input   1
        retrun  [1]

        input   123
        return  [1,2,3]

        input   123
                4 
        return  [[1,2,3],
                [4]]
    """
    if n == 0:
        return [int(k) for k in xsxs()]
    else:
        return [[int(k) for k in xsxs()] for _ in range(n)]


def xsxs(n=0):
    """
    args:
        int n: a number of lows to read 
    example:
        input   AA
        retrun  AA

        input   A BBB CC
        return  ["A","BBB","CC"]

        input   A BB CCC
                D
        return  [["A","BBB","CC"],
                ["D"]]
    """
    if n == 0:
        temp = list(input().split())
        if len(temp) == 1:
            return temp[0]
        elif len(temp) > 1:
            return temp
    else:
        return [list(input().split()) for _ in range(n)]


def sp_xsxs(n=0):
    """
    args:
        int n: a number of lows to read 
        example:
            input   A
            retrun  ["A"]

            input   ABC
            return  ["A","B","C"]

            input   ABC
                    D
            return  [["A","B","C"],
                    ["D"]]
    """
    if n == 0:
        return [s for s in xsxs()]
    else:
        return [[s for s in xsxs()] for _ in range(n)]


a, v = xnxn()
b, w = xnxn()
t = xnxn()


for i in range(t):
    if b - a > 0:
        b = min(b + w, 10 ** 9)
        a = min(a + v, 10 ** 9)
        if b == a:
            print("YES")
            sys.exit()
    elif b - a < 0:
        b = max(b - w, 10 ** 9)
        a = max(a - v, 10 ** 9)
        if b == a:
            print("YES")
            sys.exit()

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

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
import sys
def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())
INF = 1000000000000

a,v = LI()
b,w = LI()
T = I()

if(a > b):
    a,b = b,a
    v,w = w,v

if(a == b):
    print('YES')
else:
    low = 0
    high = T

    while(low <= high):
        mid = (low + high) // 2
        val = b - a + (w-v)*mid
        if(val == 0):
            print('YES')
            break
            
        elif(val > 0):
            low = mid + 1
        else:
            high = mid - 1

    if(val != 0):
        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(V - W)
D = abs(A - B)
if(S == 0):
    print('NO')
    exit(0)

#print(S, D)
if((A - B) * (V - W) >= 0):
    print('NO')
    exit(0)

#print(S, D)
if(D / S > T):
    print('NO')
    exit(0)
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 B+W*T<=A+V*T 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())

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

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

Submission status: Wrong Answer

Solution code:
A, S_A = map(int, input().split(' '))
B, S_B = map(int, input().split(' '))
T = int(input())

distance = B - A

is_catchable = (S_A - S_B) * T >= distance
if is_catchable:
    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())

for i in range(t):
    oni = a+v*(i+1)
    ngr = b+w*(i+1)

    if oni == ngr:
        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 V == W:
    print("NO")
    exit()

B = B - A
A = 0

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

Submission status: Wrong Answer

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

def main():
    if V >= W:
        print("NO")
        return
    
    
    elif abs(B-A)//abs(V-W) <= T:
        print("YES")
    else:
        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:
    kyo=B-A
if A>B:
    kyo=A=B

sub=V-W

ans=-1
for i in range(T):
    if A==B:
        print("YES")
        break
    if V<=W:
        print("NO")
        break
    
    ans=kyo-sub
    if ans<=0:
        print("YES")
        break
    kyo=ans
if ans>0:
    print("NO")

Submission status: Wrong Answer

Solution code:
def resolve():
    a, v = map(int, input().split())
    b, w = map(int, input().split())
    t = int(input())
    dis = abs(a-b)
    spe = abs(v-w)
    if (v-w) <= 0:
        print("No")
        return
    time = dis / spe
    if (v-w) > 0 and time <= t:
        print("YES")
    else:
        print("NO")
resolve()

Submission status: Wrong Answer

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

if A == B:
  print('YES')
  sys.exit()
elif A < B:
  T = -T

posA = A + V*T
posB = B + W*T

if T >= 0:
  if posA < posB:
    print('YES')
  else:
    print('NO')
else:
  if posA > posB:
    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 tt in range(t):
  if v<w:
    v=v+a*t
    w=w+b*t
  elif v>w:
    v=v-a*t
    w=w-b*t
  if v is 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())

position_diff = b-a
pace_diff = v-w

if pace_diff <= 0:
    print('NO')
elif pace_diff > 0:
    if pace_diff * t >= position_diff:
        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(1,T+1):
    if (A+V*i)-(B+W*i) == 0:
        print("YES")
        break;
    elif i == T:
        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:
    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')
else:
    print('YES')

Submission status: Wrong Answer

Solution code:
a=input().split(' ')
b=input().split(' ')
c=int(input())
i=0
d=int(a[0])
e=int(a[1])
f=int(b[0])
g=int(b[1])
if i<c:
    d=d+(e*c-1)
    f=f+(g*c-1)
if f>d:
    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())

r=a+t*v
s=b+t*w
if a>b and r>s:
    print('NO')
elif a<b and r<s:
    print('NO')
else:
    print('YES')

Submission status: Wrong Answer

Solution code:
import sys

orga = list(map(float, input().split()))
child = list(map(float, input().split()))
time = float(input())

if orga[1] <= child[1]:
    print("No")
    sys.exit()

dis = abs(orga[0] - child[0])
if dis / (orga[1] - child[1]) <= time:
    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())


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

Submission status: Wrong Answer

Solution code:
s=input().split()
a=int(s[0])
v=int(s[1])
s=input().split()
b=int(s[0])
w=int(s[1])
t=int(input())
a+=v*t
b+=w*t
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())
 
d = b-a
 
if v-w == 0:
    print("NO")
        
else:
    if a>b:
        if (v+w)*t>=d:
            print("YES")
        else:
            print("NO")
    else:
        if (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())
ans = 0

for i in range(1,t+1):
    a_place = a + v*i
    b_place = b + w*i
    if a_place == b_place:
        ans += 1
    break
        
if ans >= 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 a == b:
    print('YES')
elif v == w:
    print('NO')
else:
    if abs(a - b) % (v - w) == 0 and abs(a - b) // (v - w) <= t and v > w:
        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
    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 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 a== b:
    print("YES")
    exit()

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

k = b - a
tm = v -w

for _ in range(t):
    k = k - tm
    if k== 0:
        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())

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

Submission status: Wrong Answer

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

if abs(a-b) <= (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=abs(B-A)
vd=V-W

if V <= W:
	print("No")
elif L <= vd*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")
else:
    if abs(b-a)>=(t*(v-w)):
        print("NO")
    else:
        if abs(b-a)%(v-w)==0 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
y = B
for i in range(T):
    x = x + V
    y = y + W
    if x > y:
        print("YES")
        break
    else:
        print("NO")
        break

Submission status: Wrong Answer

Solution code:
def iput(): return int(input())
def mput(): return map(int, input().split())
def lput(): return list(map(int, input().split()))

def solve():
    a, v = mput()
    b, w = mput()
    t = iput()
    bit = 0
    if a == b:
        bit = 1
    if b > a:
        if v > w:
            if ((b-a)/(v-w))%1 == 0 and t >= ((b-a)/(v-w)) >= 0:
                bit = 1
    else:
        if w > v:
            if ((a-b)/(w-v))%1 == 0 and t >= ((a-b)/(w-v)) >= 0:
                bit = 1
    if bit == 1:
        print("YES")
    else:
        print("NO")
    return 0

if __name__ == "__main__":
    solve()

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)
  flag = False
  if 0 < dt and t >= dt:
    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())

total_a=a+v*t
total_b=b+w*t
if a<b:

    if total_a>=total_b:
        print("YES")

    else:
        print("NO")

else:
    if total_b>=total_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())

flag = False
for t in range(T):
    if abs(A-B) == abs(V-W)*t:
        flag = True
        break


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=input()
if ((V-W)*int(T)) <= 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())
dis=abs(a-b)
speed=v-w
if speed>0 and dis%speed==0 and dis/speed<=t:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

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

    x = V - W
    c = abs(B - A)
    ans = c - x * T

    if ans <= 0:
        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())

c = abs(b-a)
x = v - w


if x <= 0:
    print("NO")
    exit()

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

Submission status: Wrong Answer

Solution code:
a=input().split(' ')
b=input().split(' ')
c=int(input())
i=0
d=int(a[0])
e=int(a[1])
f=int(b[0])
g=int(b[1])
if i<c:
    d=d+(e*c-1)
    f=f+(g*c-1)
print(f,d)
if f>d:
    print('NO')
else:
    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())
h0=V*T+A
h1=W*T+B
if h0>=h1:
    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 V*i+A >= W*i+B:
        print('YES')
        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())

ans = "NO"

if(A<B):
    if(A+V*T > B+W*T):
        ans = "YES"
elif(A>B):
    if(A+(-1)*V*T < B+(-1)*W*T):
        ans = "YES"
print(ans)

Submission status: Wrong Answer

Solution code:
import sys

A,V = map(int,input().split())
B,W = map(int,input().split())
T = int(input())
if V == W:
  print("NO")
  sys.exit()
t= (B-A)%(V-W)
a = (B-A)//(V-W)
if t == 0:
  if (B >= A and T >=a >=0) or (A>B and -T<=a <=0) or (A == B):
    print('YES')
  else:
    print('NO')
    

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())
if a>b:
    nigeru = t*w
    if 10**9+b<=t*w:
        nigeru=10**9+b
    if nigeru>v*t+a-b:
        print("NO")
        sys.exit()
    else:
        print("YES")
        sys.exit()
if a<b:
    nigeru=t*w
    if 10**9-b<=t*w:
        nigeru=10**9-b
    if nigeru>t*v-(b-a):
        print("NO")
        sys.exit()
    else:
        print("YES")
        sys.exit()

Submission status: Wrong Answer

Solution code:
a,v=map(int,input().split(" "))
b,w=map(int,input().split(" "))
t=int(input())
c=a
d=b
l=0
for i in range(t):
  if(c==d):
    l=l+1
    print("YES")
    break
  c=c+v
  d=d+w
if(l==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 B - A <= 0:
    print("YES")
else:
    if (V-W) * T >= B - 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())
if a < b:
    if (v-w)*t >= b-a:
        print('YES')
    else:
        print('NO')
elif b > a:
    if (v-w)*t >= a-b:
        print("YES")
    else:
        print("NO")

Submission status: Wrong Answer

Solution code:
#from statistics import median
#import collections
#aa = collections.Counter(a) # list to list || .most_common(2)で最大の2個とりだせるお a[0][0]
from fractions import gcd
#from itertools import combinations # (string,3) 3回
#from collections import deque
#from collections import deque,defaultdict
#import bisect
#
#    d = m - k[i] - k[j]
#    if kk[bisect.bisect_right(kk,d) - 1] == d:
#
#
#
# pythonで無理なときは、pypyでやると正解するかも！！
#
#

import sys
sys.setrecursionlimit(10000000)
mod = 10**9 + 7
#mod = 9982443453
def readInts():
  return list(map(int,input().split()))
def I():
  return int(input())
a,v = readInts()
b,w = readInts()
t = I()
ab = abs(a-b)
sa = abs(w - v)
if sa == 0:
    print('NO')
    exit()
if a == b:
    print('YES')
elif a < b and v <= w:
    print('NO')
elif a > b and v >= w:
    print('YES')
elif ab/sa <= 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)
Y = V-W
if (V<=W):
  print('NO')
elif ((X%Y) == 0) and ((X/Y)<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 = b-a

print(d,(v-w)*t)
 
if v-w == 0:
    print("NO")
        
else:
    if a>b:
        if (v+w)*t>=d:
            print("YES")
        else:
            print("NO")
    else:
        if (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())
if V == W:
    print("NO")
else:
    if abs(B - A) // (V - W) > 0 and abs(B - A) // (V - W) <= T:
        print("YES")
    elif A + V * T >= 10 ** 9 or A - V * T <= -1 * (10 ** 9):
        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())
c = a + t * v
d = b + t * w
if(a > b):
  if(c <= d):
    print("YES")
  else:
    print("NO")
elif(a == b):
    print("YES")
else:
  if(c >= 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())
for _ in range(t):
    if a == b:
        print('YES')
        exit()
    elif a < b:
        a += v
        b += w
    else:
        a -= v
        b -= w
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:
    if (V-W)*T >= max(A,B) - min(A,B) and (max(A,B) - min(A,B))%(V-W) == 0:
        print('YES')
    else:
        print('NO')

Submission status: Wrong Answer

Solution code:
A, S_A = map(int, input().split(' '))
B, S_B = map(int, input().split(' '))
T = int(input())

distance = B - A

is_catchable = (S_A - S_B) * T > distance
if is_catchable:
    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())

l1 = a + v * t
l2 = b + w * t

flag = False
if v >= 0:
    if a > b and w <= 0:
        pass
    elif l1 >= l2:
        flag = True
else:
    if b > a and w >= 0:
        pass
    elif l1 <= l2:
        flag = True
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())

if V-W <= 0:
  print("NO")
elif B-A <= 0:
  print("NO")
else:
  if ((B-A)/(V-W)) <= T:
    q, mod= divmod(B-A, V-W)
    if mod == 0:
      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:
  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:
import sys

a,b=map(int,input().split())
c,d=map(int,input().split())
t=int(input())
if(d>b):
	print("NO")
else:

	x=(b-d)
	p1=a+t*b
	p2=c+t*d

	if(x==0):
		if(a==c):
			print("YES")
		else:
			print("NO")
	elif(p1>=p2):
		print("YES")
	else:
		print("NO")

Submission status: Wrong Answer

Solution code:
[a, v] = raw_input().split()
[b, w] = raw_input().split()
t = int(raw_input())
if int(v) <= int(w): print 'NO'
if int(a) > int(b):
    m = int(a) - int(b)
else:
    m = int(b) - int(a)
s = int(v) - int(w)
if s * t >= m:
    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())


diff1 = abs(A - B)
diff2 = (V - W)*T

if ( diff1 < diff2):
  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())
if V <= W:
    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())
if B+W*T<=A+V*T or B<A:
    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 a + v * t * (-1) < b + w * t * (-1):
        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())
print('YES' if (V-W)*T >= (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 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 v <= w:

  print('NO') 

else:

  q = abs(a-b) / abs(v - w) 

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

for t in range(T):
    if B+W*T == A+V*T:
        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())
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())
import sys
x = 0
while x<t:
    if a+v == b+w:
        print('YES')
        sys.exit()
    else:
        a = a+v
        b = b+w
        x = x+1
print('NO')
'''if v-w != 0:
    if not b-a > 0 and w-v > 0:
        if (a-b)/(v-w) > t:
            print('NO')
        elif (a-b)/(w-v) < t:
            print('YES')
        else:
            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())

dis =  (b + w*t) - (a + v*t) 
if dis > 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")
else:
  if b > a:
    if (b-a) <= (v-w)*t:
        print("YES")
    elif a+w*t >= 10**9 and a+v*t >= -10**9:
      print("YES")
    else:
        print("NO")
  else:
    if b-w*t <= -10**9 and a-v*t <= -10**9:
      print("YES")
    elif (a-b) <= (v-w)*t:
      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())

l = b-a
v_l = v-w
if (l < v_l * 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())
dv = V - W
dist = abs(B - A)
if V > W:
    if dv * T >= dist:
        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 = input()
for i in range(int(t)):
  m = a + v*i
  n = b + w*i
  if m == n:
    print('Yes')
    break
else:
  print('No')

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
import sys


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

    a = V * T + A
    b = W * T + B

    if (A < B and a >= b) or (A > B and a <= b) or A == B:
        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())

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

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(a - b)
sokudo = v-w

if kyori<t*sokudo:
  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())

aa = v * t
bb = w * t

if aa - bb >= abs(b - 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())

d = B - A
s = (V - W) * T

if (d > 0) & (s >= 0):
  if d <= s:
    print("YES")
  else:
    print("NO")
elif (d < 0) & (s >= 0):
  print("NO")
elif (d > 0) & (s < 0):
  print("NO")
else:
  if d >= s:
    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())
res = False
A = abs(A) + V*T
B = abs(B) + W*T
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())

dx = b - a
dv = v - w

if dv <= 0:
    print('NO')

elif dx % dv == 0 and dx // dv <= 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())

# # 愚直に
diff_pos = A-B
diff_spd = V-W

if (diff_spd <= 0) :
    print("NO")
elif (diff_pos > diff_spd * (T)) :
    print("NO")
else :
    print("YES")

# for i in range(1,T+1) :
#     if (B < A) :
#         A = A + V
#         B = B + go_pos * W
#     if (B_pos)