Answers for "three way communication codechef solution"

0

three way communication codechef solution

import math
t=int(input())
for i in range(t):
  r=int(input())
  x1,y1=map(int,input().split())
  x2,y2=map(int,input().split())
  x3,y3=map(int,input().split())
  a=math.sqrt((x1-x2)**2+(y1-y2)**2)
  b=math.sqrt((x1-x3)**2+(y1-y3)**2)
  c=math.sqrt((x2-x3)**2+(y2-y3)**2)
  if r>=a and r>=b:
    print("yes")
   elif r>=c and(r>=a or r>=b):
    print("yes")
    else:
      print("no")
Posted by: Guest on May-31-2020

Code answers related to "three way communication codechef solution"

Python Answers by Framework

Browse Popular Code Answers by Language