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



Sample input:
0 0 0 1


Sample output:
-1 1 -1 0

Submission status: Accepted

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

dx, dy = x2-x1, y2-y1

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

print(x3, y3, x4, y4)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import numpy as np
x1, y1, x2, y2 = map(int, input().split())

a = np.array([x2-x1, y2-y1])
rot = np.array([[0, 1], [-1, 0]])
b = np.dot(a, rot)
print (x2 + b[0], y2 + b[1], x1 + b[0], y1 + b[1])

Submission status: Accepted

Solution code:
import sys
input=sys.stdin.readline
import math

def main():

    x1,y1,x2,y2 = map(int, input().split())
    t = math.pi/2
    x3 = x2 + (x2-x1) * math.cos(t) - (y2-y1) * math.sin(t)
    y3 = y2 + (x2-x1) * math.sin(t) + (y2-y1) * math.cos(t)
    x4 = x3 + (x3-x2) * math.cos(t) - (y3-y2) * math.sin(t)
    y4 = y3 + (x3-x2) * math.sin(t) + (y3-y2) * math.cos(t)
    print(round(x3), round(y3), round(x4), round(y4))

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
A = [int(x) for x in input().split()]
a=A[2]-A[0]
b=A[3]-A[1]
print(A[2]-b,A[3]+a,A[0]-b,A[1]+a)

Submission status: Accepted

Solution code:
#coding:utf-8
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)

Submission status: Accepted

Solution code:
def test():
    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__":
    test()

Submission status: Accepted

Solution code:
import math
import numpy as np
x1, y1, x2, y2 = map(int, input().split())
c1 = [x1, y1]
c2 = [x2, y2]
v = [x2-x1, y2-y1]
d = int(math.sqrt(v[0]*v[0] + v[1]*v[1]))
rotate_matrix = ([0, 1], [-1, 0])

v4 = np.dot(v, rotate_matrix)
v3 = [v4[0] + v[0], v4[1] - v[1]]

c4 = c1 + v4
c3 = c2 + v4

print(c3[0],c3[1],c4[0],c4[1])

Submission status: Accepted

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

Submission status: Accepted

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

x_diff=x2-x1
y_diff=y2-y1

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

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

Solution code:
def main():
    x1, y1, x2, y2 = map(int, input().split())
    v1 = x2-x1
    v2 = y2-y1
    x3, y3 = x2-v2, y2+v1
    x4, y4 = x3-v1, y3-v2
    return x3, y3, x4, y4

if __name__ == '__main__':
    output = main()
    print(" ".join(map(str, output)))

Submission status: Accepted

Solution code:
X1, Y1, X2, Y2 = map(int, input().split())
print(X2 - Y2 + Y1, Y2 + X2 - X1, X1 - Y2 + Y1, Y1 + X2 - X1)

Submission status: Accepted

Solution code:
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("{} {} {} {}".format(x3, y3, x4, y4))

Submission status: Accepted

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

Submission status: Accepted

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

x_sa = x2 - x1
y_sa = y2 - y1
print(x2 - y_sa, y2 + x_sa, x1 - y_sa, y1 + x_sa)

Submission status: Accepted

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

Submission status: Accepted

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

diff1 = x2 - x1
diff2 = y2 - y1

x3, y3 = x2 - diff2, y2 + diff1
x4, y4 = x3 - diff1, y3 - diff2

print(x3, y3, x4, y4)

Submission status: Accepted

Solution code:
x1,y1,x2,y2 = list(map(int, input().split()))
dif = x2-x1
dif2 = y2-y1
l = [x2 - dif2, y2 + dif, x1 - dif2, y1 + dif]
ll = [str(i) for i in l]
print(" ".join(ll))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
import sys
import queue
from collections import Counter
from itertools import accumulate
from fractions import gcd
from functools import reduce


def lcm(a, b):
    return a * b // gcd(a, b)

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

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

sys.setrecursionlimit(10000)

mod = 1000000007

"""
# 0埋め, 小数点出力桁指定時のときの出力
a = 100
b = 0.987654321
print("{0:06d}-{1:6f}".format(a,b))
000100-0.987654

# 文字列をリストに格納
char_list = list("abcd") # ["a","b","c","d"]

# 標準入力取得
## 文字列
    = sys.stdin.readline().rstrip()
    = list(sys.stdin.readline().rstrip())

## 数値
    = int(sys.stdin.readline())
    = map(int, sys.stdin.readline().split())
    = list(map(int, sys.stdin.readline().split()))
    = [list(map(int,list(sys.stdin.readline().split()))) for i in range(N)]
"""

from math import sin
from math import cos
from math import radians as rad
import numpy as np

if __name__ == "__main__":
    x1, y1, x2, y2 = map(int, sys.stdin.readline().split())
    p1 = np.array([x1, y1])
    p2 = np.array([x2, y2])
    Rot = np.array([[cos(rad(90)), -sin(rad(90))], [sin(rad(90)), cos(rad(90))]])

    p3 = np.dot(Rot, p2 - p1) + p2
    p4 = np.dot(Rot, p3 - p2) + p3    
    print(int(round(p3[0])), int(round(p3[1])), int(round(p4[0])), int(round(p4[1])))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = (int(i) for i in input().split())
x3 = y1 -y2 +x2
y3 = x2 -x1 +y2
x4 = y1 -y2 +x1
y4 = x2 -x1 +y1
print(x3,y3,x4,y4)

Submission status: Accepted

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

Submission status: Accepted

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

difx = x2 - x1
dify = y2 - y1

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

print(x3, y3, x4, y4)

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
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 INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

x1, y1, x2, y2 = MAP()

a = x2 - x1
b = y2 - y1

x3, y3 = x2 - b, y2 + a
x4, y4 = x3 - a, y3 - b

print(x3, y3, x4, y4)

Submission status: Accepted

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

d1 = x2-x1
d2 = y2-y1

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

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

print(x3,y3,x4,y4)

Submission status: Accepted

Solution code:
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)

main()

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = [int(x) for x in input().split()]
print(x2+y1-y2,y2+x2-x1,x1+y1-y2,y1+x2-x1)

Submission status: Accepted

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

import numpy as np
R=pow((x1-x2)**2+(y1-y2)**2,0.5)
x3=pow(2,0.5)*R/R*(x2-x1-(y2-y1))/pow(2,0.5)+x1
y3=pow(2,0.5)*R/R*(y2-y1+x2-x1)/pow(2,0.5)+y1
x3=int(x3)
y3=int(y3)
x4=-R*(y2-y1)/R+x1
y4=R*(x2-x1)/R+y1
x4=int(x4)
y4=int(y4)
print(x3,y3,x4,y4)

Submission status: Accepted

Solution code:
def solve():
    x1, y1, x2, y2 = list(map(int, input().split()))
    dx, dy = x2 - x1, y2 - y1
    x3, y3 = x2 - dy, y2 + dx
    x4, y4 = x3 - dx, y3 - dy
    return " ".join([str(i) for i in [x3, y3, x4, y4]])


if __name__ == "__main__":
    print(solve())

Submission status: Accepted

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

L = [int(v) for v in input().split()]

print(L[1] + L[2] - L[3], L[2] - L[0] + L[3], L[1] + L[0] - L[3], L[2] - L[0] + L[1])

Submission status: Accepted

Solution code:
n = list(map(int,input().split()))

p1 = (int(n[0]) + int(n[1]) * 1j)
p2 = (int(n[2]) + int(n[3]) * 1j)

p3 = (p2 - p1) * 1j + p2
p4 = p3 + (p1 - p2)

print(int(p3.real), int(p3.imag), int(p4.real), int(p4.imag))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = list(map(int, input().split()))
alp = x2 - x1
beta = y1 - y2
print(x2 + beta, y2 + alp, x2 + beta - alp, y2 + alp + beta)

Submission status: Accepted

Solution code:

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(x3, y3, x4, y4)

Submission status: Accepted

Solution code:
x_1,y_1,x_2,y_2=map(int,input().split())
temp = [x_2-x_1,y_2-y_1]
x_3 = x_2 - temp[1]
y_3 = y_2 + temp[0]
x_4 = x_1 - temp[1]
y_4 = y_1 + temp[0]

print(str(x_3) + " " + str(y_3) + " " + str(x_4) + " " + str(y_4))

Submission status: Accepted

Solution code:
# -*-coding: utf-8 -*-
a, b, c, d = map(int, input().split())
# (x1, y1)を原点に移動させる
c -= a
d -= b
if c > 0 and d >= 0:     # 第一象限
    e = c - d
    f = c + d
    g = -abs(d)
    h = abs(c)
elif c <= 0 and d > 0:       # 第二象限
    e = c - abs(d)
    f = d - abs(c)
    g = -abs(d)
    h = -abs(c)
elif c < 0 and d <= 0:       # 第三象限
    e = c + abs(d)
    f = d - abs(c)
    g = abs(d)
    h = -abs(c)
else:       # 第四象限
    e = c + abs(d)
    f = d + abs(c)
    g = abs(d)
    h = abs(c)

print("{} {} {} {}".format(e+a , f+b , g+a ,h+b))

Submission status: Accepted

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

x12 = x2 -x1
y12 = y2 -y1

x3 = x2-y12
y3 = y2+x12

x4 = x1-y12
y4 = y1+x12

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

Submission status: Accepted

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

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

print(x3,y3,x4,y4)

Submission status: Accepted

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


vector_x1 = x1 - x2
vector_y1 = y1 - y2

x3 = x2 + vector_y1
y3 = y2 - vector_x1

vector_x2 = x2 - x3
vector_y2 = y2 - y3

x4 = x3 + vector_y2
y4 = y3 - vector_x2

print(x3,y3,x4,y4)

Submission status: Accepted

Solution code:
x1,y1,x2,y2=input().split()
x1,y1,x2,y2=int(x1),int(y1),int(x2),int(y2)
x3=x2+y1-y2
y3=y2+x2-x1
x4=x1+y1-y2
y4=y1+x2-x1
print(" ".join([str(x3),str(y3),str(x4),str(y4)]))

Submission status: Accepted

Solution code:
import math
import copy
import sys

inputa = input().split()
# inputb = input().split()
# inputc = input().split()

# a = int(inputa[0])
# b = int(inputa[1])
# c = int(inputa[2])

# x = int(inputb[0])
# y = int(inputb[1])

inputaList = [int(n) for n in inputa]

# inputb = input().split()
# inputbList = [int(n) for n in inputb]
#
# inputList = []
# inputNumList = []
# for i in range(a):
#     inputNum = input().split()
#     inputNumList = list(inputNum[0])
#     inputList.append(inputNumList)

# inputList = [int(n) for n in inputList]

# b = [int(n) for n in inputb]
# c = [int(n) for n in inputc]

x1 = inputaList[0]
y1 = inputaList[1]
x2 = inputaList[2]
y2 = inputaList[3]

edgeDisx = x2 - x1
edgeDisy = y2 - y1

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

print(x3, y3, x4, y4)

Submission status: Accepted

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

Submission status: Accepted

Solution code:


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

x = x2 - x1
y = y2 - y1
print('{0} {1} {2} {3}'.format(x2 - y, y2 + x, x1 - y, y1 + x))

Submission status: Accepted

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

x12 = x2-x1
y12 = y2-y1

x23 = -y12
y23 = x12

x34 = -y23
y34 = x23

x3 = x2 + x23
x4 = x3 + x34
y3 = y2 + y23
y4 = y3 + y34

print(x3,y3,x4,y4)

Submission status: Accepted

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

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

for item in [x3, y3, x4, y4]:
  print(item, end=" ")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
from collections import deque

sys.setrecursionlimit(4100000)


def inputs(num_of_input):
    ins = [input() for i in range(num_of_input)]
    return ins


def _euclid(x, y):
    if x > y:
        large = x
        small = y
    else:
        large = y
        small = x

    if small == 0:
        return large

    return _euclid(small, large % small)


def euclid_multi(nums):
    if len(nums) == 1:
        return nums[0]

    e = -1
    for i in range(1, len(nums)):
        if e == -1:
            e = _euclid(nums[0], nums[1])
        else:
            e = _euclid(e, nums[i])
    return e


def solve(inputs):
    [x1, y1, x2, y2] = string_to_int(inputs[0])
    diff_x = x2 - x1
    diff_y = y2 - y1
    x3 = x2 - diff_y
    y3 = y2 + diff_x
    x4 = x1 - diff_y
    y4 = y1 + diff_x
    return "{} {} {} {}".format(x3, y3, x4, y4)


def string_to_int(string):
    return list(map(int, string.split()))


if __name__ == "__main__":
    ret = solve(inputs(1))
    print(ret)

Submission status: Accepted

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

x = x2 - x1
y = y2 - y1

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

Submission status: Accepted

Solution code:
x,y,xx,yy = list(map(int,input().split()))
print(xx-(yy-y), yy+(xx-x) ,x-(yy-y) , y+(xx-x))

Submission status: Accepted

Solution code:
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( str(x3) + " " +str(y3) + " " +str(x4) + " " +str(y4))

Submission status: Accepted

Solution code:
import numpy as np
x1,y1,x2,y2 = list(map(int,input().split()))
p1 = np.array([x1,y1])
p2 = np.array([x2,y2])
rot = np.array([[0,-1],[1,0]])
p3 = p2 + np.dot(rot,(p2-p1))
p4 = p3 - (p2-p1)
print(p3[0],p3[1],p4[0],p4[1])

Submission status: Accepted

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

diff_1 = c - a
diff_2 = d - b

e = c - diff_2
f = d + diff_1
g = e - diff_1
h = f - diff_2

print('{} {} {} {}'.format(e,f,g,h))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
from operator import itemgetter

def rotate(x, y):
	return (-y, x)

def main():
	x1, y1, x2, y2 = map(int, input().strip().split())
	v = (x2-x1, y2-y1)
	lp = (x2, y2)
	for i in range(2):
		v = rotate(v[0], v[1])
		next = lp[0]+v[0], lp[1]+v[1]
		print("{} {} ".format(next[0], next[1]), end="")
		lp = next
	print("")
	# d = max(abs(x1 - x2), abs(y1 - y2))
	# if y1 > y2:
	# 	print(" ".join(map(str, [x2+d, y2, x2+d, y1])))
	# elif y1 < y2:
	# 	print(" ".join(map(str, [x2-d, y2, x2-d, y1])))
	# elif x1 > x2:
	# 	print(" ".join(map(str, [x2, y2-d, x1, y2-d])))
	# elif x1 < x2:
	# 	print(" ".join(map(str, [x2, y2+d, x1, y2+d])))

if __name__ == '__main__':
	main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
put = list(map(int,input().split()))
xdiff = put[2] - put[0]
ydiff = put[3] - put[1]
zero = put[2:4]
ans = []
for _ in range(2):
  xdiff,ydiff = -ydiff,xdiff
  zero[0] += xdiff
  zero[1] += ydiff
  ans += zero
print(' '.join(list(map(str,ans))))

Submission status: Accepted

Solution code:
# 2019/08/06

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

xx=x2-x1
yy=y2-y1

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

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

Solution code:
words = lambda t : list(map(t, input().split()))
x1,y1,x2,y2 = words(int)

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

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

print(x3,y3,x4,y4)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b,c,d=map(int,input().split())
x=c-a;y=d-b
e=c-y;f=d+x;g=e-x;h=f-y
print(e,f,g,h)

Submission status: Accepted

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

s,t = x2-x1, y2-y1

x3,y3 = x2-t, y2+s

s,t = x3-x2, y3-y2

x4,y4 = x3-t, y3+s

print(x3,y3,x4,y4)

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

Solution code:
# ABC 108, B - ruined square
tmp = [int(el) for el in input().split(' ')]

y = tmp[3] - tmp[1]
x = tmp[2] - tmp[0]

print(tmp[2]-y, tmp[3]+x, tmp[0]-y, tmp[1]+x)

Submission status: Accepted

Solution code:
points = list(map(int, input().split(' ')))
point1 = {'x': points[0], 'y': points[1]}
point2 = {'x': points[2], 'y': points[3]}

delta_x = point2['x'] - point1['x']
delta_y = point2['y'] - point1['y']

point3 = {
  'x': point2['x'] - delta_y,
  'y': point2['y'] - (-delta_x)
}

delta_x = point3['x'] - point2['x']
delta_y = point3['y'] - point2['y']

point4 = {
  'x': point3['x'] - delta_y,
  'y': point3['y'] - (-delta_x)
}

print(point3['x'], point3['y'], point4['x'], point4['y'])

Submission status: Accepted

Solution code:
if __name__ == '__main__':
    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(str(x3) + " " + str(y3) + " " + str(x4) + " " + str(y4))

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(int, input().split())
x3 = x2 + y1 - y2
y3 = y2 - x1 + x2
x4 = x3 + y2 - y3
y4 = y3 - x2 + x3
print(' '.join( map(str, [x3, y3, x4, y4]) ))

Submission status: Accepted

Solution code:
l = [int(i) for i in input().split(" ")]
x1 = l[0]
y1 = l[1]
x2 = l[2]
y2 = l[3]
diff_x21 = x2-x1
diff_y21 = y2-y1
y3 = y2 + diff_x21
x3 = x2 - diff_y21
x4 = x3-diff_x21
y4 = y3-diff_y21
print(x3,y3,x4,y4)

Submission status: Accepted

Solution code:

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)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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(str(x3)+' '+str(y3)+' '+str(x4)+' '+str(y4))

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

x=x2-x1
y=y2-y1

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

Submission status: Accepted

Solution code:
a,b,c,d = map(int,input().split())
import numpy as np
one =[a,b]
two =[c,d]
A = np.array(one)
B = np.array(two)
vec = B-A
C = B+np.array([-vec[1],vec[0]])
D = C+np.array([-vec[0],-vec[1]])
print(C[0],C[1],D[0],D[1])

Submission status: Accepted

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

a = (x2 - x1, 0)
b = (0, y2 - y1)

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

Submission status: Accepted

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

x=x2-x1
y=y2-y1

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

Submission status: Accepted

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

a = x2 - x1
b = y2 - y1

print(str(x2 - b) + ' ' + str(y2 + a) + ' ' + str(x1 - b) + ' ' + str(y1 + a))

Submission status: Accepted

Solution code:
li=list(map(int,input().split()))
X=li[2]-li[0]
Y=li[3]-li[1]
L = [li[2]-Y,li[3]+X,li[0]-Y,li[1]+X]
print(' '.join(map(str, L)))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
inLst = list(map(int, input().split()))

anslst = []
anslst.append(inLst[2] - (inLst[3] - inLst[1]))
anslst.append(inLst[3] + (inLst[2] - inLst[0]))
anslst.append(anslst[0] - (inLst[2] - inLst[0]))
anslst.append(anslst[1] - (inLst[3] - inLst[1]))

for i in anslst:
    print(i, end=' ')

Submission status: Accepted

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

dx = abs(c - a)
dy = abs(b - d)

if c >= a and d > b:
  e = c - dy
  f = d + dx
  g = e - dx
  h = f - dy
  print(e, f, g, h)
elif c < a and d >= b:
  e = c - dy
  f = d - dx
  g = e + dx
  h = f - dy
  print(e, f, g, h)
elif d < b and c <= a:
  e = c + dy
  f = d - dx
  g = e + dx
  h = f + dy
  print(e, f, g, h)
else:
  e = c + dx
  f = d + dy
  g = e - dx
  h = f + dy
  print(e, f, g, h)

Submission status: Accepted

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

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

Submission status: Accepted

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

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

print(x3, y3, x4, y4)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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(str(x3)+' '+str(y3)+' '+str(x4)+' '+str(y4))

Submission status: Accepted

Solution code:
z = list(map(int,input().split()))
#print(K)

x1, y1, x2, y2 =z[0],z[1],z[2],z[3] 
dx = x2-x1
dy = y2-y1
z1 = [0]*4
z1[0] = x2-dy
z1[1] = y2+dx
z1[2] = z1[0] - dx
z1[3] = z1[1] - dy

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

Submission status: Accepted

Solution code:
x0,y0,x1,y1=map(int,input().split())

#print(x0,y0,x1,y1)

dx=x1-x0
dy=y1-y0

x2=x1-dy
y2=y1+dx

x3=x2-dx
y3=y2-dy

print(x2,y2,x3,y3)

Submission status: Accepted

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

Submission status: Accepted

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

x = c-a
y = d-b

e = c-y
f = d+x
g = e-x
h = f-y
ans =[str(e), str(f), str(g), str(h)]

print(" ".join(ans))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

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

Submission status: Accepted

Solution code:
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("{} {} {} {}".format(x3, y3, x4, y4))

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(int,input().split())
vec_x = y1 - y2
vex_y = x2 - x1
ans = list(map(str, [x2+vec_x, y2+vex_y, x1+vec_x, y1+vex_y]))
print(" ".join(ans))

Submission status: Accepted

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

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

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

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

Submission status: Accepted

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

w = x2 - x1
h = y2 - y1

x3 = x2 - h
y3 = y2 + w

x4 = x1 - h
y4 = y1 + w

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

Submission status: Accepted

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

x3, y3 = x1 + dx - dy, y1 + dy + dx
x4, y4 = x1 - dy, y1 + dx

print(x3, y3, x4, y4)

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
#ABC108 B

x1,y1,x2,y2 = list(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)

Submission status: Accepted

Solution code:
ax, ay, bx, by = map(int, input().split())
c = bx - ax
d = by - ay
ex = bx - d
ey = by + c
fx = ax - d
fy = ay + c
print(str(ex) + " " + str(ey) + " " + str(fx) + " " + str(fy))

Submission status: Accepted

Solution code:
#n = int(input())
x1, y1, x2, y2 = map(int,input().split())
#ls = list(map(int,input().split()))
#ls = [list(map(int,input().split())) for i in range(n)]
#ls = [input() for i in range(n)]
X = (x2 - x1)
Y = (y2 - y1)

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
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('{} {} {} {}'.format(x3, y3, x4, y4))

Submission status: Accepted

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

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

resolve()

Submission status: Accepted

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

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

print(x3, y3, x4, y4)

Submission status: Accepted

Solution code:
a,b,c,d=map(int,input().split())
x,y=c-a,d-b
h,i,j,k=c-y,d+x,a-y,b+x
print(h,i,j,k)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
x1,y1,x2,y2 = map(int, input().split())
ori = np.array([x1,y1])
vec = np.array([x2-x1,y2-y1])
def rotation(pi,a,b):
    rot = np.matrix([[np.cos(pi),-np.sin(pi)],
                     [np.sin(pi),np.cos(pi)]])
    return np.dot(rot, [a,b])

p3 = np.sqrt(2)*(rotation(np.pi/4, vec[0], vec[1])) + ori
p4 = rotation(np.pi/2, vec[0], vec[1]) + ori

x3 = int(round(p3[0,0]))
y3 = int(round(p3[0,1]))
x4 = int(round(p4[0,0]))
y4 = int(round(p4[0,1]))

print(x3,y3,x4,y4)

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = map(int, input().split())
X = x2 - x1
Y = y2 - y1

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

Submission status: Accepted

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

Submission status: Accepted

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

a = x2-x1
b = y2-y1

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
nl = lambda: list(map(int, input().split()))
sl = lambda: input().split()
n = lambda: int(input())
s = lambda: input()

x1, y1, x2, y2 = nl()

xd = x2 - x1
yd = y2 - y1
print(x2 - yd, y2 + xd, x2 - yd - xd, y2 + xd - yd)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

vec = (x2 - x1, y2 - y1)
# p3
vec = (-vec[1], vec[0])
x3 = x2 + vec[0]
y3 = y2 + vec[1]
# p4
vec = (-vec[1], vec[0])
x4 = x3 + vec[0]
y4 = y3 + vec[1]

print(x3, y3, x4, y4)

Submission status: Accepted

Solution code:
x,y,X,Y=map(int,input().split())
print(X-Y+y)
print(Y-x+X)
print(x-Y+y)
print(y-x+X)

Submission status: Accepted

Solution code:
x1, y1, x2, y2 = (int(i) for i in input().split())
x4 = x1 - (y2 - y1)
y4 = y1 + (x2 - x1)
x3 = x4 - (y1 - y4)
y3 = y4 + (x1 - x4)
print(x3, y3, x4, y4)