Problem:
 Score : 200 points    Problem Statement There is a square in the xy -plane. The coordinates of its four vertices are (x_1,y_1),(x_2,y_2),(x_3,y_3) and (x_4,y_4) in counter-clockwise order.
(Assume that the positive x -axis points right, and the positive y -axis points up.)  Takahashi remembers (x_1,y_1) and (x_2,y_2) , but he has forgot (x_3,y_3) and (x_4,y_4) .  Given x_1,x_2,y_1,y_2 , restore x_3,y_3,x_4,y_4 . It can be shown that x_3,y_3,x_4 and y_4 uniquely exist and have integer values.      Constraints  |x_1|,|y_1|,|x_2|,|y_2| \leq 100  (x_1,y_1) ≠ (x_2,y_2)  All values in input are integers.         Input Input is given from Standard Input in the following format:  x_1  y_1  x_2  y_2       Output Print x_3,y_3,x_4 and y_4 as integers, in this order.        Sample Input 1 0 0 0 1      Sample Output 1 -1 1 -1 0  (0,0),(0,1),(-1,1),(-1,0) is the four vertices of a square in counter-clockwise order.
Note that (x_3,y_3)=(1,1),(x_4,y_4)=(1,0) is not accepted, as the vertices are in clockwise order.       Sample Input 2 2 3 6 6      Sample Output 2 3 10 -1 7       Sample Input 3 31 -41 -59 26      Sample Output 3 -126 -64 -36 -131

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

dx = x1 - x2
dy = y1 - y2
print(x2 + dy, y2 - dx, x1 + dy, y1 - dx)

Solution (Python):
x1,y1,x2,y2 = list(map(int,input().split()))
x = x2-x1
y = y2-y1
print(x2-y,y2+x,x1-y,y1+x)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

dx = x2 - x1
dy = y2 - y1

x3 = x2 - dy
y3 = y2 + dx

x4 = x3 - dx
y4 = y3 - dy

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())

x3=x2-(y2-y1)
y3=y2+(x2-x1)
x4=x3-(x2-x1)
y4=y3-(y2-y1)
  
print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
a = x2 - x1
b = y2 - y1
x3 = x2 - b
y3 = y2 + a
x4 = x1 - b
y4 = y1 + a
print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx, dy = x1 - x2, y1 - y2

x3 = x2 + dy
y3 = y2 - dx

x4 = x1 + dy
y4 = y1 - dx

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x = x2-x1
y = y2-y1
x3,y3 = x2-y,y2+x
x4,y4 = x1-y,y1+x
print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

a = x2 - x1
b = y2 - y1
x3 = x2 - b
y3 = y2 + a

print(x3, end=' ')
print(y3, end=' ')
print(x3 - a, end=' ')
print(y3 - b)

Solution (Python):
a,b,c,d = map(int,(input().split()))
x = c-a
y = d-b
print(c-y,d+x,c-y-x,d+x-y)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

vec = (x2-x1, y2-y1)

vec = (-vec[1], vec[0])

x3 = x2 + vec[0]
y3 = y2 + vec[1]

vec = (-vec[1], vec[0])

x4 = x3 + vec[0]
y4 = y3 + vec[1]

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a=x2-x1
b=y2-y1
x3=x2-b
y3=y2+a
x4=x3-a
y4=y3-b
print(x3,y3,x4,y4)

Solution (Python):
def solve():

    x1, y1, x2, y2 = map(int, input().split())

    midx = x2-x1
    midy = y2-y1

    print(x2-midy, y2+midx, x1-midy, y1+midx)


if __name__ == "__main__":
    solve()

Solution (Python):
import sys
import heapq
import re
from itertools import permutations
from bisect import bisect_left, bisect_right
from collections import Counter, deque
from fractions import gcd
from math import factorial, sqrt
from functools import lru_cache, reduce
INF = 1 << 60
mod = 1000000007
sys.setrecursionlimit(10 ** 7)
input = sys.stdin.readline


class UnionFind():
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]

    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)

        if x == y:
            return

        if self.parents[x] > self.parents[y]:
            x, y = y, x

        self.parents[x] += self.parents[y]
        self.parents[y] = x

    def size(self, x):
        return -self.parents[self.find(x)]

    def same(self, x, y):
        return self.find(x) == self.find(y)

    def members(self, x):
        root = self.find(x)
        return [i for i in range(self.n) if self.find(i) == root]

    def roots(self):
        return [i for i, x in enumerate(self.parents) if x < 0]

    def group_count(self):
        return len(self.roots())

    def all_group_members(self):
        return {r: self.members(r) for r in self.roots()}

    def __str__(self):
        return '\n'.join('{}: {}'.format(r, self.members(r)) for r in self.roots())


def dijkstra_heap(s, edge, n):
    
    d = [10**20] * n
    used = [True] * n 
    d[s] = 0
    used[s] = False
    edgelist = []
    for a,b in edge[s]:
        heapq.heappush(edgelist,a*(10**6)+b)
    while len(edgelist):
        minedge = heapq.heappop(edgelist)
        
        if not used[minedge%(10**6)]:
            continue
        v = minedge%(10**6)
        d[v] = minedge//(10**6)
        used[v] = False
        for e in edge[v]:
            if used[e[1]]:
                heapq.heappush(edgelist,(e[0]+d[v])*(10**6)+e[1])
    return d


def factorization(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])

    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([n, 1])

    return arr


def lcm(x, y):
    return (x * y) // gcd(x, y)


def lcm_list(numbers):
    return reduce(lcm, numbers, 1)


def gcd_list(numbers):
    return reduce(gcd, numbers)


x1, y1, x2, y2 = map(int, input().split())
x3 = x2 + y1 - y2
y3 = y2 + x2 - x1
x4 = x3 - x2 + x1
y4 = y3 + y1 - y2
print(x3, y3, x4, y4)

Solution (Python):
x_1,y_1,x_2,y_2=map(int,input().split())
s=x_2-x_1
t=y_1-y_2
print(x_2+t,y_2+s,x_1+t,y_1+s)

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

x_dis = c-a
y_dis = d-b
A = c-y_dis
B = d+x_dis
C = a-y_dis
D = b+x_dis
print(A,B,C,D)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a,s=x2-x1,y2-y1
print(-s+x2,y2+a,x1-s,y1+a)

Solution (Python):
X = list(map(int,input().split(' ')))
A = [X[1]+X[2]-X[3], -X[0]+X[2]+X[3], X[0]+X[1]-X[3], -X[0]+X[1]+X[2]]
print(str(X[1]+X[2]-X[3])+' '+str(-X[0]+X[2]+X[3])+' '+str(X[0]+X[1]-X[3])+' '+str(-X[0]+X[1]+X[2]))

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())

a = x2 - x1
b = y2 - y1
print(x2-b,y2+a,x1-b,y1+a)

Solution (Python):
x1,y1,x2,y2=[int(i) for i in input().split()]
a=[x2-x1,y2-y1]
b=[y1-y2,x2-x1]
x3=x1+a[0]+b[0]
y3=y1+a[1]+b[1]
x4=x3-a[0]
y4=y3-a[1]
print(x3,y3,x4,y4)

Solution (Python):
import sys
stdin = sys.stdin

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
nn = lambda: list(stdin.readline().split())
ns = lambda: stdin.readline().rstrip()


x1,y1,x2,y2 = na()
x = x2-x1
y = y2-y1

print(x2-(y2-y1), y2+x2-x1, x1-y2+y1,y1+x2-x1)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x3,y3,x4,y4 = x2 + y1-y2,y2 + x2-x1, x1 + y1-y2, y1 + x2-x1
print(x3,y3,x4,y4)

Solution (Python):
x_1,y_1,x_2,y_2=map(int,input().split())
x_4=x_1-y_2+y_1
y_4=y_1+x_2-x_1
x_3=x_4+x_2-x_1
y_3=y_4+y_2-y_1
print(x_3,y_3,x_4,y_4)

Solution (Python):
x1, y1, x2, y2 = map(int,input().split())
vec = [x2-x1,y2-y1]
x3 = x2 - vec[1]
y3 = y2 + vec[0]
x4 = x3 - vec[0]
y4 = y3 - vec[1]
print(x3,y3,x4,y4)

Solution (Python):
a,b,c,d= input().split()
x1,y1,x2,y2=(int(a),int(b),int(c), int(d))
x_dif = x2-x1
y_dif = y2-y1
x_d = abs(x_dif)
y_d=abs(y_dif)
w = x1
z =y2
y =x2
x = y1
if x_dif == 0:
    if y_dif > 0:
        print(x2-abs(y_dif),z,y-abs(y_dif),x)
    else:
        print(x2+abs(y_dif),z,y+abs(y_dif),x)
elif y_dif ==0:
    if x_dif > 0:
        print(x2,y2+abs(x_dif),w,z+abs(x_dif))
    else:
        print(x2,y2-abs(x_dif),w,z-abs(x_dif))
elif x_dif >0 and y_dif >0:
    print(x2- y_d, y2 + x_d, x1-y_d,y1+x_d)
elif x_dif >0 and y_dif <0:
    print(x2+ y_d, y2 + x_d, x1+y_d,y1+x_d)
elif  x_dif <0 and y_dif <0:
    print(x2+y_d, y2 - x_d, x1+y_d,y1-x_d)
elif  x_dif <0 and y_dif >0:
    print(x2- y_d, y2 - x_d, x1-y_d, y1-x_d)

Solution (Python):
a,b,c,d = map(int,input().split())
y = d -b
x = c -a
print(c-y,d+x,a-y,b+x)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
x3=x2-(y2-y1)
y3=y2+(x2-x1)
x4=x1-(y2-y1)
y4=y1+(x2-x1)
print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

x3 = x2 - (y2-y1)
y3 = y2 + (x2-x1)
x4 = x1 - (y2-y1)
y4 = y1 + (x2-x1)

print(x3, y3, x4, y4)

Solution (Python):
def ii():return int(input())
def iim():return map(int,input().split())
def iil():return list(map(int,input().split()))
def ism():return map(str,input().split())
def isl():return list(map(str,input().split()))

x1,y1,x2,y2 = iim()
difx = x2-x1
dify = y2-y1
x3 = x2-dify
y3 = y2+difx
x4 = x3-difx
y4 = y3-dify

print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2= list(map(int, input().split()))
y3=y2+(x2-x1)
y4=y3-y2+y1
x3=x2+y1-y2
x4=x3-x2+x1
print(x3,y3,x4,y4)

Solution (Python):
b = list(map(int, input().split()))
x1=b[0]
y1=b[1]
x2=b[2]
y2=b[3]
xkyori=abs(x1-x2)
ykyori=abs(y1-y2)
if x1>=x2:
    if y1>=y2:
        print(x2+ykyori,y2-xkyori,x1+ykyori,y1-xkyori)
    else:
        print(x2-ykyori,y2-xkyori,x1-ykyori,y1-xkyori)
else:
    if y1>=y2:
        print(x2 + ykyori, y2 + xkyori, x1 + ykyori, y1 + xkyori)
    else:
        print(x2-ykyori,y2+xkyori,x1-ykyori,y1+xkyori)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
x = x2 - x1
y = y2 - y1
print(x2 - y, y2 + x, x1 - y, y1+x)

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

e = c - a
f = d - b 

print(c-f, d+e, a-f, b+e)

Solution (Python):
a, b, c, d = list(map(int, input().split()))

e = c - a
f = d - b 

print(c-f, d+e, a-f, b+e)

Solution (Python):

def RuinedSquare(x1 , y1 , x2 , y2):

    x3 = x2 - (y2 - y1)
    y3 = y2 + (x2 - x1)
    x4 = x1 - (y2 - y1)
    y4 = y1 + (x2 - x1)

    return str(x3) + " " + str(y3) + " " + str(x4) + " " + str(y4)

def main():
    x1 , y1 , x2 , y2 = map(int , input().split())
    print(RuinedSquare(x1 , y1 , x2 , y2))

if __name__ == '__main__':
    main()

Solution (Python):
x1, y1, x2, y2 = [int(i) for i in input().split()]

x_diff = x2 - x1
y_diff = y2 - y1

x3 = x2 - y_diff
y3 = y2 + x_diff
x4 = x1 - y_diff
y4 = y1 + x_diff

print(x3, y3, x4, y4)

Solution (Python):

a, b, c, d = map(int, input().split())

x = c - a
y = d - b

print(c - y, d + x, a - y, b + x)

Solution (Python):
x0,y0,x1,y1 = map(int,input().split(" "))
x3 = x1 - (y1-y0)
x4 = x0 - (y1-y0)
y3 = y1 + (x1-x0)
y4 = y0 + (x1-x0)
print("{} {} {} {}".format(x3,y3,x4,y4))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

a=x2-x1
b=y2-y1
x3 = x2 - b
y3 = y2 + a
x4 = x3 - a
y4 = y3 - b
print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
print(x2 - (y2 - y1), y2 + (x2 - x1), x1 - (y2 - y1), y1 + (x2 - x1))

Solution (Python):
def main():
    x1, y1, x2, y2 = map(int, input().split())

    print(x2 - y2 + y1, y2 + x2 - x1, x1 - y2 + y1, y1 + x2 - x1)

if __name__ == '__main__':
    main()

Solution (Python):
x1, y1, x2, y2 = [int(_) for _ in input().split()]
vx, vy = x2 - x1, y2- y1
vx, vy = -vy, vx
x3, y3 = x2 + vx, y2 + vy
vx, vy = -vy, vx
x4, y4 = x3 + vx, y3 + vy
print(x3, y3, x4, y4)

Solution (Python):
a=list(map(int,input().split()))
x=a[2]-a[0]
y=a[3]-a[1]
print(a[2]-y,a[3]+x,a[2]-y-x,a[3]+x-y,end=" ")

Solution (Python):


import sys
import math
from bisect import bisect_right as br
from bisect import bisect_left as bl
sys.setrecursionlimit(2147483647)
from heapq import heappush, heappop,heappushpop
from collections import defaultdict
from itertools import accumulate
from collections import Counter
from collections import deque
from operator import itemgetter
from itertools import permutations
mod = 10**9 + 7
inf = float('inf')
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))

x1,y1,x2,y2 = LI()
X = y2 - y1
Y = x2 - x1
x3,y3 = x2-X, y2+Y
x4,y4 = x3-Y, y3-X
print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = tuple(map(int, input().split(' ')))
x3 = x2 - (y2 - y1)
y3 = y2 + (x2 - x1)
x4 = x3 - (y3 - y2)
y4 = y3 + (x3 - x2)
print(x3, y3, x4, y4)

Solution (Python):
x, y , xx, yy = map(int,input().split())

ans=[0,0,0,0]

ans[0] = xx-yy+y
ans[1] = yy+xx-x
ans[2] = x-yy+y
ans[3] = y+xx-x

print(ans[0],ans[1],ans[2],ans[3])

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx = x2-x1; dy = y2-y1
x3 = x2-dy; y3 = y2+dx
x4 = x1-dy; y4 = y1+dx
print(x3, y3, x4, y4)

Solution (Python):
if __name__ == "__main__":
    x1, y1, x2, y2 = map(int, input().split())

    x4 = x1 - (y2 - y1)
    y4 = y1 + (x2 - x1)

    x3 = x4 + (x2-x1)
    y3 = y4 + (y2-y1)

    print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx = x2-x1; dy = y2-y1
x3 = x2-dy; y3 = y2+dx
x4 = x1-dy; y4 = y1+dx
print(x3, y3, x4, y4)

Solution (Python):
if __name__ == "__main__":
    x1, y1, x2, y2 = map(int, input().split())

    x4 = x1 - (y2 - y1)
    y4 = y1 + (x2 - x1)

    x3 = x4 + (x2-x1)
    y3 = y4 + (y2-y1)

    print(x3, y3, x4, y4)

Solution (Python):
a,b,c,d = map(int, input().split())
print(c-d+b, d+c-a, a-d+b, b+c-a)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a=x2-x1
b=y2-y1
x3=x2-b
y3=y2+a
print("{} {} {} {}".format(x3,y3,x3-a,y3-b))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
d1, d2 = x2 - x1, y2 - y1
x3, y3 = x2 - d2, y2 + d1
x4, y4 = x3 - d1, y3 - d2
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x3 = x2 + y1 - y2
y3 = y2 + x2 - x1
x4 = x3 + x1 - x2
y4 = y3 + y1 - y2
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
x=x2-x1
y=y2-y1
print((x2-y),(y2+x),(x1-y),(y1+x))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
v1 = [x2 - x1, y2 - y1]
v = [-v1[1], v1[0]]

x3, y3 = x2 + v[0], y2 + v[1]
x4, y4 = x1 + v[0], y1 + v[1]

print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
v = [x2 - x1, y2 - y1]
s = [x2 - v[1], y2 + v[0]]
t = [s[0] - v[0], s[1] - v[1]]
print(s[0], s[1], t[0], t[1])

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx = x1 - x2
dy = y1 - y2

x3 = x2 + dy
y3 = y2 - dx

x4 = x1 + dy
y4 = y1 - dx

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = list(map(int,input().split()))
dx,dy = x2-x1,y2-y1
print(x2-dy,y2+dx,x1-dy,y1+dx)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

b = y2-y1
a = x2-x1
x3 = x2-b
y3 = y2+a
x4 = x1-b
y4 = y1+a

print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
X, Y = (x2 - x1, y2 - y1)
x3 = x2 - Y
y3 = y2 + X
x4 = x3 - X
y4 = y3 - Y
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
vec=[x2-x1,y2-y1]

x3,y3=x2-vec[1],y2+vec[0]
x4,y4=x3-vec[0],y3-vec[1]

print(str(x3)+" "+str(y3)+" "+str(x4)+" "+str(y4))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
delta_x = x1 - x2
delta_y = y1 - y2
x4 = delta_y + x1
y4 = -1 * delta_x + y1
x3 = x4 - delta_x
y3 = y4 - delta_y
print(x3, y3, x4, y4)

Solution (Python):
x1,y1 , x2,y2 = map(int,input().split())

print("{} {} {} {}".format(x2 - (y2 - y1),y2 + (x2 - x1), x1 - (y2 - y1), y1 + (x2 - x1)))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
yd = y2 - y1
xd = x2 - x1

x3 = x2 - yd
y3 = y2 + xd

x4 = x3 - xd
y4 = y3 - yd

print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

x4, y4 = x1 + y1 - y2, y1 - x1 + x2
x3, y3 = x2 + y1 - y2, -x1 + x2 + y2

print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())



deltax1_2 = x2 - x1
deltay1_2 = y2 - y1






x3 = x2 - deltay1_2
y3 = y2 + deltax1_2
x4 = x1 - deltay1_2
y4 = y1 + deltax1_2


print("{} {} {} {}".format(x3,y3,x4,y4))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

deltax2_1 = x1 - x2
deltay2_1 = y1 - y2
deltax1_2 = x2 - x1
deltay1_2 = y2 - y1

x3 = x2 + deltay2_1
y3 = y2 - deltax2_1
x4 = x1 - deltay1_2
y4 = y1 + deltax1_2


print("{} {} {} {}".format(x3,y3,x4,y4))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
print(x2 + y1 - y2, x2 - x1 + y2, x1 + y1 - y2, x2 - x1 + y1)

Solution (Python):
a,b,c,d=map(int,input().split())
x=c-a
y=d-b
print(c-y,d+x,a-y,b+x)

Solution (Python):
a,b,c,d=map(int,input().split())
x=c-a
y=d-b
print(c-y,d+x,a-y,b+x)

Solution (Python):

x1, y1, x2, y2 = map(int, input().split())

print("{0} {1} {2} {3}".format(x2 - (y2 - y1), y2 + (x2 - x1), x1 - (y2 - y1), y1 + (x2 - x1)))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx, dy = (x2-x1), (y2-y1)

print(x2-dy, y2+dx, x1-dy, y1+dx)

Solution (Python):
x_1, y_1, x_2, y_2 = map(int, input().split())
print(*(x_2 + y_1 - y_2, y_2 - x_1 + x_2, x_1 + y_1 - y_2, y_1 - x_1 + x_2))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
x3 = y1 - y2 + x2
y3 = -(x1 - x2) + y2
x4 = -(y2 - y1) + x1
y4 = x2 - x1 + y1
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
x4=y1-y2+x1
y4=x2-x1+y1
x3=x4+y4-y1
y3=y4+x1-x4
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
dx,dy=x2-x1,y2-y1
print(x2-dy,y2+dx,x1-dy,y1+dx)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

x3 = x2 + (y1 - y2)
y3 = y2 - (x1 - x2)

x4 = x3 + (x1 - x2)
y4 = y3 + (y1 - y2)

print(*[x3, y3, x4, y4])

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

a = x2 - x1
b = y2 - y1

x3 = x2 - b
x4 = x1 - b
y3 = y2 + a
y4 = y1 + a

print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

dx, dy = x2 - x1, y2 - y1

x3, y3 = (x2 - dy, y2 + dx)
x4, y4 = (x1 - dy, y1 + dx)

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
y = y2 -y1
x = x2 -x1
print(x2-y,y2+x,x1-y,y1+x)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a=x2-x1
b=y2-y1
print(x2-b,y2+a,x1-b,y1+a)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split(' '))

x = (x2 - x1)
y = (y2 - y1)

print(x2 - y, y2 + x, x1 - y, y1 + x)

Solution (Python):
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, acos, atan, asin
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from fractions import gcd
def input(): return sys.stdin.readline().strip()
def STR(): return input()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def S_MAP(): return map(str, input().split())
def LIST(): return list(map(int, input().split()))
def S_LIST(): return list(map(str, input().split()))
sys.setrecursionlimit(10 ** 9)
inf = sys.maxsize
mod = 10 ** 9 + 7

x1, y1, x2, y2 = MAP()
a = complex(x1, y1)
b = complex(x2, y2)
rot = complex(cos(pi / 2), sin(pi / 2))
c = b + (b - a) * rot
d = a + (b - a) * rot
print(int(round(c.real, 0)), int(round(c.imag, 0)), int(round(d.real, 0)), int(round(d.imag, 0)))

Solution (Python):

x1, y1, x2, y2 = map(int,input().split()) 

l = pow(x1 - x2, 2) + pow(y1 - y2, 2)

a1 = complex(x1, y1)
a2 = complex(x2, y2)
a3 = complex(0, -1) * (a1 - a2) + a2
a4 = complex(0, -1) * (a2 - a3) + a3
x3 = int(a3.real)
y3 = int(a3.imag)
x4 = int(a4.real)
y4 = int(a4.imag)
print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = [int(x) for x in input().split()]

x3 = x2 + y1 - y2
y3 = x2 - x1 + y2
x4 = x1 + y1 - y2
y4 = x2 - x1 + y1

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=list(map(int,input().split()))
a=(x2-x1)
b=(y2-y1)

print(x2-b,y2+a,x1-b,y1+a)

Solution (Python):
from __future__ import print_function

import sys

import re
import array
import copy
import functools
import operator

import math
import string
import fractions
from fractions import Fraction
from fractions import gcd



import collections
import itertools
import bisect

import random
import time

import heapq
from heapq import heappush
from heapq import heappop
from heapq import heappushpop
from heapq import heapify
from heapq import heapreplace
from queue import PriorityQueue as pq
from queue import Queue

from itertools import accumulate

from collections import deque
from collections import Counter

from operator import mul
from functools import reduce

input = sys.stdin.readline


def eprint(*args, **kwargs):
    print(*args, file=sys.stderr, **kwargs)
    return


def lcm(n, m):
    return int(n * m / gcd(n, m))


def coprimize(p, q):
    common = fractions.gcd(p, q)
    return (p // common, q // common)


def combinations_count(n, r):
    r = min(r, n - r)
    numer = reduce(mul, range(n, n - r, -1), 1)
    denom = reduce(mul, range(1, r + 1), 1)
    return numer // denom


def main():
    a_x,a_y, b_x,b_y = map(int,input().strip().split())
    e1=b_x - a_x
    e2=b_y-a_y
    c_x=b_x-e2
    c_y=b_y+e1
    d_x=c_x-e1
    d_y=c_y-e2
    print(c_x,c_y,d_x,d_y)
    


if __name__ == '__main__':
    main()

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

x3 = x2+(y1-y2)
y3 = y2-(x1-x2)
x4 = x1+(y1-y2)
y4 = y1-(x1-x2)
print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(complex, input().split())
OA = x1 + y1 * 1j
OB = x2 + y2 * 1j
OD = (1 - 1j) * OA + 1j * OB
OC = OD + OB - OA

x4, y4 = int(OD.real), int(OD.imag)
x3, y3 = int(OC.real), int(OC.imag)
print(x3, y3, x4, y4)

Solution (Python):
def main():
    x1, y1, x2, y2 = map(int, input().split())
    edge_x = x2 - x1
    edge_y = y2 - y1
    x3, y3 = x2 - edge_y, y2 + edge_x
    x4, y4 = x1 - edge_y, y1 + edge_x
    print(x3, y3, x4, y4)


if __name__ == "__main__":
    main()

Solution (Python):

x1,y1,x2,y2=map(int,input().split())
dx=x2-x1
dy=y2-y1
x3=x2+dy*(-1)
y3=y2+dx
dx=x3-x2
dy=y3-y2
x4=x3+dy*(-1)
y4=y3+dx
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())

x3=x2-(y2-y1)
y3=y2+(x2-x1)

x4=x3-(x2-x1)
y4=y3-(y2-y1)

print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = [int(elem) for elem in input().split()]

x = x2 - x1
y = y2 - y1

x3 = x2 - y
y3 = y2 + x
x4 = x1 - y
y4 = y1 + x
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x = x2 - x1
y = y2 - y1
print(x2 - y, y2 + x,x1 - y,y1 + x)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
vec = [x2-x1,y2-y1]

x3,y3 = x2-vec[1] ,y2+vec[0]
x4,y4 = x1-vec[1], y1+vec[0]

print("{} {} {} {}".format(x3,y3,x4,y4))

Solution (Python):
x1,y1,x2,y2 = map(int, input().split())

dx = x2 - x1
dy = y2 - y1

x3 = x2 - dy
y3 = y2 + dx

x4 = x3 - dx
y4 = y3 - dy

print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())

x3=x2-(y2-y1)
y3=y2+(x2-x1)
x4=x3-(y3-y2)
y4=y3+(x3-x2)

print(x3,y3,x4,y4)

Solution (Python):


x1,y1,x2,y2 = list(map(int, input().rstrip().split()))


dx = x2-x1
dy = y2-y1

x3 = x2 - dy
y3 = y2 + dx

x4 = x3 - dx
y4 = y3 - dy

print(x3,y3,x4,y4)

Solution (Python):

x1,y1,x2,y2=map(int,input().split())
dx=x2-x1
dy=y2-y1
x3=x2-dy
y3=y2+dx
x4=x1-dy
y4=y1+dx
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())

x3 = x2+(y1-y2)
y3 = y2-(x1-x2)
x4 = x3+(x1-x2)
y4 = y3+(y1-y2)

print(x3,y3,x4,y4)

Solution (Python):
a,b,c,d=map(int,input().split())
print(c-d+b,d+c-a,a-d+b,b+c-a)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
x3=x2-(y2-y1)
y3=y2+(x2-x1)
x4=x3-(x2-x1)
y4=y3-(y2-y1)
print(x3,y3,x4,y4)

Solution (Python):


import sys
 
stdin = sys.stdin
inf = 1 << 60
mod = 1000000007
 
ni = lambda: int(ns())
nin = lambda y: [ni() for _ in range(y)]
na = lambda: list(map(int, stdin.readline().split()))
nan = lambda y: [na() for _ in range(y)]
nf = lambda: float(ns())
nfn = lambda y: [nf() for _ in range(y)]
nfa = lambda: list(map(float, stdin.readline().split()))
nfan = lambda y: [nfa() for _ in range(y)]
ns = lambda: stdin.readline().rstrip()
nsn = lambda y: [ns() for _ in range(y)]
ncl = lambda y: [list(ns()) for _ in range(y)]
nas = lambda: stdin.readline().split()

x1, y1, x2, y2 = na()

x = x2 - x1
y = y2 - y1
print(x2 - y, y2 + x, x1 - y, y1 + x)

Solution (Python):
x1,y1,x2,y2=map(int, input().split())
x3=x2+y1-y2
y3=y2+x2-x1
x4=x1+y1-y2
y4=y1+x2-x1
print(x3,y3,x4,y4)

Solution (Python):
import numpy as np
import fractions

x1,y1,x2,y2=map(int,input().split())
xd=x2-x1
yd=y2-y1
print(x2-yd,y2+xd,x1-yd,y1+xd)

Solution (Python):

x1, y1, x2, y2 = [int(str) for str in input().strip().split()]

v23x = y1 - y2
v23y = x2 - x1

x3, y3 = x2 + v23x, y2 + v23y

v34x = y2 - y3
v34y = x3 - x2

x4, y4 = x3 + v34x, y3 + v34y

print(x3, y3, x4, y4)

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

def main():
    x1, y1, x2, y2 = map(int, input().split())
    x = x2 - x1
    y = y2 - y1
    print(x2 - y, y2 + x, x1 - y , y1 + x)

if __name__ == '__main__':
    main()

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

x_diff = x2 - x1
y_diff = y2 - y1

print(x2 - y_diff, y2 + x_diff, x1 - y_diff, y1 + x_diff)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
dx,dy=x2-x1,y2-y1
print(x2-dy,y2+dx,x1-dy,y1+dx)

Solution (Python):
import math
import string


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


def nCr(n, r):
    return math.factorial(n)//(math.factorial(n-r)*math.factorial(r))


def has_duplicates2(seq):  
    seen = []
    for item in seq:
        if not(item in seen):
            seen.append(item)
    return len(seq) != len(seen)


def divisor(n):
    divisor = []
    for i in range(1, n+1):
        if n % i == 0:
            divisor.append(i)
    return divisor


a, b, c, d = map(int, input().split())
x = c-a
y = d-b
print(c+(-y), d+x, a+(-y), b+x)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
X = x2 - x1
Y = y2 - y1
x3 = x2 - Y
y3 = y2 + X
x4 = x1 - Y
y4 = y1 + X
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
d = [x1-x2,-(y1-y2)]
print(x2-d[1],y2-d[0],x1-d[1],y1-d[0])

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
X = x2 - x1
Y = y2 - y1
x3 = x2 - Y
y3 = y2 + X
x4 = x1 - Y
y4 = y1 + X
print(x3, y3, x4, y4)

Solution (Python):


x1,y1,x2,y2 = list(map(int,input().split()))

y = y2-y1
x = x2-x1

m = [x2-y,y2+x,x1-y,y1+x]


print(*m)

Solution (Python):



x_1,y_1,x_2,y_2=map(int,input().split())
b=y_2-y_1
a=x_2-x_1
print(x_2-b,y_2+a,x_1-b,y_1+a)

Solution (Python):



x_1,y_1,x_2,y_2=map(int,input().split())
b=y_2-y_1
a=x_2-x_1
print('{} {} {} {}'.format(x_2-b,y_2+a,x_1-b,y_1+a))

Solution (Python):



x_1,y_1,x_2,y_2=map(int,input().split())
x_3=x_2-(y_2-y_1)
y_3=x_2-x_1+y_2
x_4=x_3-(x_2-x_1)
y_4=y_3-(y_2-y_1)
print('{} {} {} {}'.format(x_3,y_3,x_4,y_4))

Solution (Python):


x1,y1,x2,y2 = map(int,input().split())
x4 = x1-(y2-y1)
y4 = y1+(x2-x1)
x3 = x2-(y2-y1)
y3 = y2+(x2-x1)
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x4 = x1-(y2-y1)
y4 = y1+(x2-x1)
x3 = x2-(y2-y1)
y3 = y2+(x2-x1)
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x = x1 -x2
y = y1 -y2
print(x2+y,y2-x,x1+y,y1-x)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

X = x2 - x1
Y = y2 - y1

print(x2-Y, y2+X, x1-Y, y1+X)

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

x = c - a
y = d - b

print(c-y,d+x,a-y, b+x)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a=x1-x2
b=y1-y2
print(x2+b,y2-a,x1+b,y1-a)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
nvec = (y1-y2,x2-x1)
x3,y3 = x2+nvec[0],y2+nvec[1]
x4,y4 = x1+nvec[0],y1+nvec[1]
print(x3,y3,x4,y4)

Solution (Python):


x1, y1, x2, y2 = map(int,input().split())

dx = x2 - x1
dy = y2 - y1

x3, y3 = x2 - dy, y2 + dx
x4, y4 = x3 - dx, y3 - dy

print(x3, y3, x4, y4)

Solution (Python):


x1, y1, x2, y2 = map(int,input().split())

b = x2 - x1
a = y1 - y2

x3 = x2 + a
y3 = y2 + b

x4 = x1 + a
y4 = y1 + b

print(x3, y3, x4, y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx = x2 - x1
dy = y2 - y1
print(x2 - dy, y2 + dx, x1 -dy, y1 + dx)

Solution (Python):
import sys

sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

x1, y1, x2, y2 = lr()
diff1 = x2 - x1
diff2 = y2 - y1
x3, y3 = x2 - diff2, y2 + diff1
x4, y4 = x1 - diff2, y1 + diff1
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2 = map(int,input().split())
x3 = x2-(y2-y1)
y3 = y2+(x2-x1)
x4 = x1-(y2-y1)
y4 = y1+(x2-x1)
print(x3,y3,x4,y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a,b=(x2-x1),(y2-y1)
print(str(x2-b)+' '+str(y2+a)+' '+str(x1-b)+' '+str(y1+a))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

diff_x = x2 - x1
diff_y = y2 - y1

x3 = x2 - diff_y
y3 = y2 + diff_x
x4 = x3 - diff_x
y4 = y3 - diff_y


print("{} {} {} {}".format(x3,y3,x4,y4))

Solution (Python):
x1,y1,x2,y2=map(int,input().split())

vec1=[(x2-x1),(y2-y1)]
vec2=[-vec1[1],vec1[0]]

ans=[x2+vec2[0],y2+vec2[1]]+[x1+vec2[0],y1+vec2[1]]
print(*ans)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx, dy = abs(x1 - x2), abs(y1 - y2)

if x1 <= x2 and y1 <= y2:
    x3, y3 = x2-dy, y2+dx
    x4, y4 = x1-dy, y1+dx
elif x1 <= x2 and y1 >= y2:
    x3, y3 = x2+dy, y2+dx
    x4, y4 = x1+dy, y1+dx
elif x1 >= x2 and y1 >= y2:
    x3, y3 = x2+dy, y2-dx
    x4, y4 = x1+dy, y1-dx
elif x1 >= x2 and y1 <= y2:
    x3, y3 = x2-dy, y2-dx
    x4, y4 = x1-dy, y1-dx    
    
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
a,b=x2-x1,y2-y1
x3,y3=x2-b,y2+a
x4,y4=x3-a,y3-b
print(x3,y3,x4,y4)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

diff_x = x2 - x1
diff_y = y2 - y1

x3 = x2 - diff_y
y3 = y2 + diff_x
x4 = x3 - diff_x
y4 = y3 - diff_y


print("{} {} {} {}".format(x3,y3,x4,y4))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dif_x = x2 - x1
dif_y = y2 - y1
print(x2 - dif_y, y2 + dif_x, x1 - dif_y, y1 + dif_x)

Solution (Python):
x1,y1,x2,y2 = map(int, input().split())
x12=x2-x1
y12=y2-y1

if x12>=0 and y12>=0:
    x3=x2-abs(y12)
    y3=y2+abs(x12)
    x4=x3-abs(x12)
    y4=y3-abs(y12)
elif x12>=0 and y12<0:
    x3=x2+abs(y12)
    y3=y2+abs(x12)
    x4=x3-abs(x12)
    y4=y3+abs(y12)
elif x12<0 and y12>=0:
    x3=x2-abs(y12)
    y3=y2-abs(x12)
    x4=x3+abs(x12)
    y4=y3-abs(y12)
else:
    x3=x2+abs(y12)
    y3=y2-abs(x12)
    x4=x3+abs(x12)
    y4=y3+abs(y12)
print('{} {} {} {}'.format(x3,y3,x4,y4))

Solution (Python):
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    x1,y1,x2,y2=INTM()
    w=x2-x1
    h=y2-y1
    x3=x2-h
    y3=y2+w
    x4=x3-w
    y4=y3-h
    print(x3,y3,x4,y4)
if __name__ == '__main__':
    do()

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())

dx, dy = x2 - x1, y2 - y1

x3 = x2 - dy
y3 = y2 + dx
x4 = x3 - dx
y4 = y3 - dy

print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())

print(x2-(y2-y1),y2+(x2-x1),x1-(y2-y1),y1+(x2-x1))

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
x3 = x2 - (y2 - y1)
y3 = y2 + (x2 - x1)
x4 = x3 - (y3 - y2)
y4 = y3 + (x3 - x2)
print(x3, y3, x4, y4)

Solution (Python):
x_1, y_1, x_2, y_2 = map(int, input().split())
x = x_2 - x_1
y = y_2 - y_1
print(x_2-y, y_2+x, x_1-y, y_1+x)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
dx = x2-x1
dy = y2- y1
print(x2-dy, y2 + dx, x1-dy, y1+dx)

Solution (Python):
x1, y1, x2, y2 = map(int, input().split())
 
x4 = x1 - (y2 - y1)
y4 = y1 + (x2 - x1)
 
x3 = x4 - (y1 - y4)
y3 = y4 + (x1 - x4)
 
print(x3, y3, x4, y4)

Solution (Python):
x1,y1,x2,y2=map(int,input().split())
print(*[x2+(y1-y2),y2+(x2-x1),x1+(y1-y2),y1+(x2-x1)])

Solution (Python):
x1,y1,x2,y2=map(int,input().split())

a=x2-x1
b=y2-y1
ans=[x2-b,y2+a,x1-b,y1+a]

for a in ans:
    print(a,end=' ')