Pashmak has fallen in love with an attractive girl called Parmida since one year ago...

Today, Pashmak set up a meeting with his partner in a romantic garden. Unfortunately, Pashmak has forgotten where the garden is. But he remembers that the garden looks like a square with sides parallel to the coordinate axes. He also remembers that there is exactly one tree on each vertex of the square. Now, Pashmak knows the position of only two of the trees. Help him to find the position of two remaining ones.


-----Input-----

The first line contains four space-separated x_1, y_1, x_2, y_2 ( - 100 ≤ x_1, y_1, x_2, y_2 ≤ 100) integers, where x_1 and y_1 are coordinates of the first tree and x_2 and y_2 are coordinates of the second tree. It's guaranteed that the given points are distinct.


-----Output-----

If there is no solution to the problem, print -1. Otherwise print four space-separated integers x_3, y_3, x_4, y_4 that correspond to the coordinates of the two other trees. If there are several solutions you can output any of them. 

Note that x_3, y_3, x_4, y_4 must be in the range ( - 1000 ≤ x_3, y_3, x_4, y_4 ≤ 1000).


-----Examples-----
Input
0 0 0 1

Output
1 0 1 1

Input
0 0 1 1

Output
0 1 1 0

Input
0 0 1 2

Output
-1

Difficulty: EASY

Solutions:
(x1, y1, x2, y2) = map(int, input().split())
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2)
elif y1 == y2:
	print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split(' '))
if x1 == x2:
	l = abs(y2 - y1)
	x3 = x1 + l
	x4 = x2 + l
	y3 = y1
	y4 = y2
	print(x3, y3, x4, y4)
elif y1 == y2:
	x3 = x1
	x4 = x2
	l = abs(x2 - x1)
	y3 = y1 + l
	y4 = y2 + l
	print(x3, y3, x4, y4)
elif abs(x2 - x1) != abs(y2 - y1):
	print(-1)
else:
	l = abs(x2 - x1)
	if y1 < y2:
		x3 = x1
		y3 = y1 + l
		x4 = x2
		y4 = y2 - l
	else:
		x3 = x1
		y3 = y1 - l
		x4 = x2
		y4 = y2 + l
	print(x3, y3, x4, y4)


(a, b, c, d) = map(int, input().split())
l = abs(a - c)
m = abs(b - d)
if a == c:
	print(a + m, b, c + m, d)
elif b == d:
	print(a, b + l, c, d + l)
elif l != m:
	print(-1)
else:
	print(a, d, c, b)


(x1, y1, x2, y2) = [int(i) for i in input().split()]
if x1 == x2:
	print(x1 + abs(y1 - y2), y1, x1 + abs(y1 - y2), y2)
elif y1 == y2:
	print(x1, y1 + abs(x1 - x2), x2, y1 + abs(x1 - x2))
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1)
else:
	print(-1)


def solve(x1, y1, x2, y2):
	if x1 == x2:
		side = abs(y2 - y1)
		x = x1 + side
		return [x, y1, x, y2]
	elif y1 == y2:
		side = abs(x2 - x1)
		y = y1 + side
		return [x1, y, x2, y]
	elif abs(x2 - x1) == abs(y2 - y1):
		return [x1, y2, x2, y1]
	else:
		return None

def main():
	(x1, y1, x2, y2) = [int(i) for i in input().strip().split()]
	result = solve(x1, y1, x2, y2)
	if result is None:
		print(-1)
	else:
		print(' '.join((str(n) for n in result)))
main()


m = list((int(x) for x in input().split()))
x1 = m[0]
y1 = m[1]
x2 = m[2]
y2 = m[3]
dx = abs(x1 - x2)
dy = abs(y1 - y2)
if not dx:
	y3 = y1
	y4 = y2
	x3 = x1 + dy
	x4 = x2 + dy
	print(x3, y3, x4, y4)
elif not dy:
	x3 = x1
	x4 = x2
	y3 = y1 + dx
	y4 = y2 + dx
	print(x3, y3, x4, y4)
elif dx == dy:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
else:
	print('-1')


def process(x1, y1, x2, y2):
	if x1 == x2:
		print('{0} {1} {0} {2}'.format(x1 + abs(y2 - y1), y1, y2))
	elif y1 == y2:
		print('{1} {0} {2} {0}'.format(y1 + abs(x2 - x1), x1, x2))
	elif abs(y2 - y1) == abs(x2 - x1):
		print('{0} {3} {2} {1}'.format(x1, y1, x2, y2))
	else:
		print(-1)

def __starting_point():
	process(*(int(i) for i in input().split(' ')))
__starting_point()


def pash(x1, y1, x2, y2):
	if x1 == x2:
		s = abs(y1 - y2)
		print(x1 + s, y1, x2 + s, y2)
	elif y1 == y2:
		s = abs(x1 - x2)
		print(x1, y1 + s, x2, y2 + s)
	elif abs(y1 - y2) == abs(x1 - x2):
		print(x1, y2, x2, y1)
	else:
		print(-1)
l = list(map(int, input().split()))
pash(l[0], l[1], l[2], l[3])


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	a = max(y1, y2) - min(y1, y2)
	print(x1 + a, y1, x2 + a, y2, sep=' ')
elif y1 == y2:
	a = max(x1, x2) - min(x1, x2)
	print(x1, y1 + a, x2, y2 + a, sep=' ')
else:
	a1 = max(x1, x2) - min(x1, x2)
	a2 = max(y1, y2) - min(y1, y2)
	if a1 != a2:
		print(-1)
	else:
		print(x1, y2, x2, y1, sep=' ')


(a, b, c, d) = input().split()
a = int(a)
b = int(b)
c = int(c)
d = int(d)
(p, q, r, s) = (0, 0, 0, 0)
if a == c and b > d:
	temp = b - d
	p = r = a + temp
	q = b
	s = d
	print(p, q, r, s)
elif a == c and b < d:
	temp = d - b
	p = r = a + temp
	q = b
	s = d
	print(p, q, r, s)
elif b == d and c > a:
	temp = c - a
	p = a
	r = c
	q = s = b + temp
	print(p, q, r, s)
elif b == d and a > c:
	temp = a - c
	p = a
	q = s = b + temp
	r = c
	print(p, q, r, s)
elif a != c and b != d:
	t1 = a - c
	t2 = b - d
	if abs(t1) == abs(t2):
		if c > a and d > b:
			temp = c - a
			p = a
			q = b + temp
			r = a + temp
			s = b
			print(p, q, r, s)
		elif c < a and d < b:
			temp = a - c
			p = a
			q = b - temp
			r = a - temp
			s = b
			print(p, q, r, s)
		elif c > a and d < b:
			temp = c - a
			p = a
			q = b - temp
			r = a + temp
			s = b
			print(p, q, r, s)
		elif c < a and d > b:
			temp = d - b
			p = a
			q = b + temp
			r = a - temp
			s = b
			print(p, q, r, s)
	else:
		print(-1)


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

def verify():
	global x1, y1, x2, y2
	if x1 != x2:
		m = abs(math.degrees(math.atan((y2 - y1) / (x2 - x1))))
	else:
		m = 90
	if m in (0, 45, 90):
		return m
	else:
		return None
slope = verify()
(x3, y3, x4, y4) = [None for i in range(4)]
if slope != None:
	distance = round(((x2 - x1) ** 2 + (y2 - y1) ** 2) ** 0.5)
	if slope in (0, 90):
		if slope == 0:
			(x3, y3) = (x1, y1 + distance)
			(x4, y4) = (x2, y2 + distance)
		else:
			(x3, y3) = (x1 + distance, y1)
			(x4, y4) = (x2 + distance, y2)
	else:
		(x3, y3) = (x1, y2)
		(x4, y4) = (x2, y1)
	print(x3, y3, x4, y4)
else:
	print('-1')


(x1, y1, x2, y2) = map(int, input().split())
a = abs(x1 - x2)
b = abs(y1 - y2)
if x1 == x2:
	print(x1 + b, y1, x2 + b, y2)
elif y1 == y2:
	print(x1, y1 + a, x2, y2 + a)
elif a != b:
	print(-1)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = list(map(int, input().split()))
if (x1 - x2) * (y1 - y2) != 0:
	if abs(x1 - x2) != abs(y1 - y2):
		print(-1)
	else:
		print(x1, y2, x2, y1)
elif x1 == x2:
	le = abs(y1 - y2)
	if x1 + le > 1000:
		x = x1 - le
	else:
		x = x1 + le
	print(x, y1, x, y2)
else:
	le = abs(x1 - x2)
	if y1 + le > 1000:
		y = y1 - le
	else:
		y = y1 + le
	print(x1, y, x2, y)


(x1, y1, x2, y2) = list(map(int, input().split()))
if x1 == x2:
	kc = abs(y1 - y2)
	print(x1 + kc, y1, x2 + kc, y2)
elif y1 == y2:
	kc = abs(x1 - x2)
	print(x1, y1 + kc, x2, y2 + kc)
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1)
else:
	print(-1)


from sys import stdin
k = list(map(int, stdin.readline().split()))
(x1, y1, x2, y2) = (k[0], k[1], k[2], k[3])
if True == True:
	if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
		print(-1)
	elif x1 == x2:
		print(str(x1 + abs(y1 - y2)) + ' ' + str(y1) + ' ' + str(x2 + abs(y1 - y2)) + ' ' + str(y2))
	elif y1 == y2:
		print(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
	else:
		print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))


def check_square(x1, y1, x2, y2):
	x = abs(x1 - x2)
	y = abs(y1 - y2)
	if x != y:
		return False
	return True

def parallel(x1, y1, x2, y2):
	if x1 - x2 == 0 or y1 - y2 == 0:
		return True
	return False
(x1, y1, x2, y2) = [int(x1) for x1 in input().split()]
(x3, y3, x4, y4) = (0, 0, 0, 0)
if parallel(x1, y1, x2, y2) == False:
	if check_square(x1, y1, x2, y2) == False:
		print(-1)
		exit()
	else:
		x3 = x1
		y3 = y2
		x4 = x2
		y4 = y1
		print(x3, y3, x4, y4)
else:
	if x1 == x2:
		tmp = abs(y1 - y2)
		x3 = x1 + tmp
		x4 = x2 + tmp
		y3 = y1
		y4 = y2
	else:
		tmp = abs(x1 - x2)
		x3 = x1
		x4 = x2
		y3 = y1 + tmp
		y4 = y2 + tmp
	print(x3, y3, x4, y4)


(x1, y1, x2, y2) = map(int, input().split())
DifX = abs(x2 - x1)
DifY = abs(y2 - y1)
if y1 == y2 and x1 != x2:
	(x3, x4) = (x1, x2)
	(y3, y4) = (y1 + DifX, y2 + DifX)
	print(x3, y3, x4, y4)
elif x1 == x2 and y1 != y2:
	(x3, x4) = (x1 + DifY, x2 + DifY)
	(y3, y4) = (y1, y2)
	print(x3, y3, x4, y4)
elif DifX == DifY and x1 != x2 and (y1 != y2):
	(x3, x4) = (x1, x2)
	(y3, y4) = (y2, y1)
	print(x3, y3, x4, y4)
else:
	print(-1)


import math, string, itertools, fractions, heapq, collections, re, array, bisect, sys, random, time, copy, functools
sys.setrecursionlimit(10 ** 7)
inf = 10 ** 20
eps = 1.0 / 10 ** 10
mod = 10 ** 9 + 7
dd = [(-1, 0), (0, 1), (1, 0), (0, -1)]
ddn = [(-1, 0), (-1, 1), (0, 1), (1, 1), (1, 0), (1, -1), (0, -1), (-1, -1)]

def LI():
	return [int(x) for x in sys.stdin.readline().split()]

def LI_():
	return [int(x) - 1 for x in sys.stdin.readline().split()]

def LF():
	return [float(x) for x in sys.stdin.readline().split()]

def LS():
	return sys.stdin.readline().split()

def I():
	return int(sys.stdin.readline())

def F():
	return float(sys.stdin.readline())

def S():
	return input()

def pf(s):
	return print(s, flush=True)

def main():
	(x1, y1, x2, y2) = LI()
	if x1 == x2:
		sa = abs(y1 - y2)
		return '{} {} {} {}'.format(x1 + sa, y1, x1 + sa, y2)
	if y1 == y2:
		sa = abs(x1 - x2)
		return '{} {} {} {}'.format(x1, y1 + sa, x2, y2 + sa)
	if abs(x1 - x2) != abs(y1 - y2):
		return -1
	return '{} {} {} {}'.format(x1, y2, x2, y1)
print(main())


def pashmak_and_garden():
	coordinates = [int(c) for c in input().split(' ')]
	(x1, y1, x2, y2) = (coordinates[0], coordinates[1], coordinates[2], coordinates[3])
	Xd = abs(x1 - x2)
	Yd = abs(y1 - y2)
	if Xd and (not Yd):
		return [x1, y1 + Xd, x2, y2 + Xd]
	elif Yd and (not Xd):
		return [x1 + Yd, y1, x2 + Yd, y2]
	elif Xd == Yd and Xd != 0:
		return [x1, y2, x2, y1]
	else:
		return [-1]
print(' '.join((str(x) for x in pashmak_and_garden())))


(x1, y1, x2, y2) = [int(x) for x in input().split()]
diff1 = diff2 = x3 = x4 = y3 = y4 = 0
if x1 != x2 and y1 != y2:
	diff1 = abs(x1 - x2)
	diff2 = abs(y2 - y1)
	if diff1 == diff2:
		x3 = x1
		x4 = x2
		y3 = y2
		y4 = y1
		print('%d %d %d %d' % (x3, y3, x4, y4))
	else:
		print(-1)
elif x1 == x2 and y1 != y2:
	diff = abs(y2 - y1)
	x3 = x1 + diff
	x4 = x2 + diff
	y3 = y1
	y4 = y2
	print('%d %d %d %d' % (x3, y3, x4, y4))
elif x1 != x2 and y1 == y2:
	diff = abs(x1 - x2)
	y3 = y1 + diff
	y4 = y2 + diff
	x3 = x1
	x4 = x2
	print('%d %d %d %d' % (x3, y3, x4, y4))
else:
	print('%d' % -1)


a = list(map(int, input().split()))
x1 = a[0]
y1 = a[1]
x2 = a[2]
y2 = a[3]
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	side = abs(y1 - y2)
	print(x1 + side, y1, x2 + side, y2)
elif y1 == y2:
	side = abs(x1 - x2)
	print(x1, y1 + side, x2, y2 + side)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split())
a = abs(x2 - x1)
b = abs(y2 - y1)
g = (a * a + b * b) ** 0.5
if a == 0 or b == 0:
	g = (a * a + b * b) ** 0.5
	if a == 0:
		x3 = x1 + g
		x4 = x2 + g
		y3 = y1
		y4 = y2
	elif b == 0:
		y3 = y1 + g
		y4 = y2 + g
		x3 = x1
		x4 = x2
	print(round(x3), round(y3), round(x4), round(y4))
elif a == b:
	y3 = y2
	x3 = x1
	y4 = y1
	x4 = x2
	print(round(x3), round(y3), round(x4), round(y4))
else:
	print('-1')


inp = input().split()
x1 = int(inp[0])
y1 = int(inp[1])
x2 = int(inp[2])
y2 = int(inp[3])
len1 = abs(x1 - x2)
len2 = abs(y1 - y2)
if len1 == 0:
	print('{0} {1} {2} {3}'.format(x1 + len2, y1, x2 + len2, y2))
	exit()
if len2 == 0:
	print('{0} {1} {2} {3}'.format(x1, y1 + len1, x2, y2 + len1))
	exit()
if len1 != len2:
	print(-1)
	exit()
print('{0} {1} {2} {3}'.format(x1, y2, x2, y1))


(x1, y1, x2, y2) = map(int, input().split())
lx = abs(x1 - x2)
ly = abs(y1 - y2)
if x1 == x2:
	print(ly + x1, y1, ly + x2, y2)
elif y1 == y2:
	length = abs(x1 - x2)
	print(x1, lx + y1, x2, lx + y2)
elif lx == ly:
	print(x1, y2, x2, y1)
else:
	print(-1)


trees = input()
trees = trees.split()
x1 = int(trees[0])
x2 = int(trees[2])
y1 = int(trees[1])
y2 = int(trees[3])
del_x = abs(x1 - x2)
del_y = abs(y1 - y2)
if del_x and del_y and (del_y != del_x):
	print('-1')
elif del_x == 0:
	print(f'{x1 + del_y} {y1} {x2 + del_y} {y2}')
elif del_y == 0:
	print(f'{x1} {y1 + del_x} {x2} {y2 + del_x}')
else:
	print(f'{x1} {y2} {x2} {y1}')


(a, b, c, d) = map(int, input().split())
if a - c != 0 and b - d != 0 and (abs(a - c) != abs(b - d)):
	print('-1')
elif b - d == 0:
	print(str(a) + ' ' + str(b + abs(c - a)) + ' ' + str(c) + ' ' + str(b + abs(c - a)))
elif a - c == 0:
	print(str(a + abs(b - d)) + ' ' + str(b) + ' ' + str(a + abs(b - d)) + ' ' + str(d))
else:
	print(str(a) + ' ' + str(d) + ' ' + str(c) + ' ' + str(b))


(x1, y1, x2, y2) = map(int, input().split())
ax = abs(x2 - x1)
ay = abs(y2 - y1)
if not ax and ay:
	x1 += ay
	x2 += ay
	print(x1, y1, x2, y2)
elif ax and (not ay):
	y1 += ax
	y2 += ax
	print(x1, y1, x2, y2)
elif ax == ay:
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = list(map(int, input().split()))
l1 = abs(x1 - x2)
l2 = abs(y1 - y2)
if x1 == x2:
	x3 = x1 + l2
	y3 = y1
	x4 = x2 + l2
	y4 = y2
	print(x3, y3, x4, y4)
elif y1 == y2:
	x3 = x1
	y3 = y1 + l1
	x4 = x2
	y4 = y2 + l1
	print(x3, y3, x4, y4)
elif l1 != l2:
	print(-1)
else:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2 or y1 == y2:
	if x1 == x2:
		k = abs(y1 - y2)
		p = k + x1
		print(p, y1, p, y2)
	else:
		k = abs(x1 - x2)
		p = k + y1
		print(x1, p, x2, p)
elif abs(y2 - y1) == abs(x2 - x1):
	print(x1, y2, x2, y1)
else:
	print('-1')


import itertools
import time

def timer(f):

	def tmp(*args, **kwargs):
		t = time.time()
		res = f(*args, **kwargs)
		print('Время выполнения функции: %f' % (time.time() - t))
		return res
	return tmp
(x1, y1, x2, y2) = map(int, input().split(' '))
if x1 == x2:
	side = abs(y2 - y1)
	x3 = x1 + side
	y3 = y1
	x4 = x2 + side
	y4 = y2
	print(x3, y3, x4, y4)
	exit(0)
if y1 == y2:
	side = abs(x2 - x1)
	x3 = x1
	y3 = y1 + side
	x4 = x2
	y4 = y2 + side
	print(x3, y3, x4, y4)
	exit(0)
side1 = abs(y2 - y1)
side2 = abs(x2 - x1)
if side1 == side2:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
else:
	print(-1)


a = list(map(int, input().split()))
x = abs(a[2] - a[0])
y = abs(a[3] - a[1])
if x == 0 or y == 0 or x == y:
	if x == 0:
		print(a[0] + y, a[1], a[0] + y, a[3])
	elif y == 0:
		print(a[0], a[1] + x, a[2], a[1] + x)
	else:
		print(a[0], a[3], a[2], a[1])
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	x3 = x1 + abs(y1 - y2)
	print(x3, y1, x3, y2)
elif y1 == y2:
	y3 = y1 + abs(x1 - x2)
	print(x1, y3, x2, y3)
elif abs(x1 - x2) != abs(y1 - y2):
	print(-1)
else:
	print(x1, y2, x2, y1)


ls = list(map(int, input().split()))
if (ls[0] == ls[2] or ls[1] == ls[3]) or (ls[0] == ls[1] and ls[2] == ls[3]) or abs(ls[0] - ls[2]) == abs(ls[1] - ls[3]):
	x0 = ls[0]
	y0 = ls[1]
	x1 = ls[2]
	y1 = ls[3]
	if x0 == x1:
		print(x0 + abs(y0 - y1), end=' ')
		print(y0, end=' ')
		print(x1 + abs(y0 - y1), end=' ')
		print(y1)
	elif y0 == y1:
		print(x0, end=' ')
		print(y0 + abs(x0 - x1), end=' ')
		print(x1, end=' ')
		print(y1 + abs(x0 - x1))
	else:
		print(x0, end=' ')
		print(y1, end=' ')
		print(x1, end=' ')
		print(y0)
else:
	print(-1)


a = []
a = input().split()
x1 = int(a[0])
y1 = int(a[1])
x2 = int(a[2])
y2 = int(a[3])
import math
t = (y2 - y1) * (y2 - y1) + (x2 - x1) * (x2 - x1)
d = int(math.sqrt(t))
if x1 == x2:
	y3 = str(y1)
	y4 = str(y2)
	x3 = str(x1 + d)
	x4 = str(x1 + d)
	print(x3 + ' ' + y3 + ' ' + x4 + ' ' + y4)
elif y1 == y2:
	x3 = str(x1)
	x4 = str(x2)
	y3 = str(d + y1)
	y4 = str(d + y1)
	print(x3 + ' ' + y3 + ' ' + x4 + ' ' + y4)
else:
	x3 = x1
	x4 = x2
	y3 = y2
	y4 = y1
	t = (y4 - y1) * (y4 - y1) + (x4 - x1) * (x4 - x1)
	d1 = int(math.sqrt(t))
	t = (y3 - y2) * (y3 - y2) + (x3 - x2) * (x3 - x2)
	d2 = int(math.sqrt(t))
	t = (y3 - y1) * (y3 - y1) + (x3 - x1) * (x3 - x1)
	d3 = int(math.sqrt(t))
	t = (y4 - y2) * (y4 - y2) + (x4 - x2) * (x4 - x2)
	d4 = int(math.sqrt(t))
	if d1 == d2 and d2 == d3 and (d3 == d4) and (d4 == d1):
		print(str(x3) + ' ' + str(y3) + ' ' + str(x4) + ' ' + str(y4))
	else:
		print('-1')


class Solution:

	def __init__(self):
		(self.x1, self.y1, self.x2, self.y2) = [int(x) for x in input().split()]

	def solve_and_print(self):
		if self.x1 == self.x2:
			print(f'{self.x1 + abs(self.y2 - self.y1)} {self.y1} {self.x2 + abs(self.y2 - self.y1)} {self.y2}')
		elif self.y1 == self.y2:
			print(f'{self.x1} {self.y1 + abs(self.x2 - self.x1)} {self.x2} {self.y2 + abs(self.x2 - self.x1)}')
		elif abs(self.y2 - self.y1) == abs(self.x2 - self.x1):
			print(f'{self.x1} {self.y2} {self.x2} {self.y1}')
		else:
			print(-1)
Solution().solve_and_print()


from math import sqrt

def main():
	(x1, y1, x2, y2) = map(int, input().split())
	if x1 == x2:
		distance = int(dist(x1, y1, x2, y2))
		print(f'{x1 + distance} {y1} {x2 + distance} {y2}')
		return
	elif y1 == y2:
		distance = int(dist(x1, y1, x2, y2))
		print(f'{x1} {y1 + distance} {x2} {y2 + distance}')
		return
	if can_mismatch(x1, y1, x2, y2):
		print(f'{x1} {y2} {x2} {y1}')
		return
	print(-1)

def can_mismatch(x1, y1, x2, y2):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	return int(dist(x1, y1, x3, y3)) == int(dist(x1, y1, x4, y4)) == int(dist(x2, y2, x3, y3)) == int(dist(x2, y2, x4, y4))

def dist(x1, y1, x2, y2):
	return sqrt((x1 - x2) ** 2 + (y1 - y2) ** 2)
main()


(x1, y1, x2, y2) = [int(i) for i in input().split()]
x_diff = abs(x1 - x2)
y_diff = abs(y1 - y2)
if x_diff != 0 and y_diff != 0:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
elif x_diff != 0:
	x3 = x1
	y3 = y1 + abs(x_diff)
	x4 = x2
	y4 = y2 + abs(x_diff)
else:
	x3 = x1 + abs(y_diff)
	y3 = y1
	x4 = x2 + abs(y_diff)
	y4 = y2
if x_diff != 0 and y_diff != 0 and (x_diff != y_diff):
	print('-1')
else:
	print(x3, y3, x4, y4)


(x1, y1, x2, y2) = input().split(' ')
x1 = int(x1)
x2 = int(x2)
y1 = int(y1)
y2 = int(y2)
dif_x = abs(x2 - x1)
dif_y = abs(y2 - y1)
dif = max(dif_x, dif_y)
if dif_x is 0:
	x3 = x1 + dif
	y3 = y1
	x4 = x2 + dif
	y4 = y2
	print(x3, y3, x4, y4)
	exit()
elif dif_y is 0:
	x3 = x1
	y3 = y1 + dif
	x4 = x2
	y4 = y2 + dif
	print(x3, y3, x4, y4)
	exit()
elif dif_x != dif_y:
	print(-1)
	exit()
else:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
	exit()


(x1, y1, x2, y2) = map(int, input().split())
if y1 > y2:
	q = y1 - y2
else:
	q = y2 - y1
if x1 > x2:
	h = x1 - x2
else:
	h = x2 - x1
if y1 == y2:
	print(x1, y1 + h, x2, y2 + h)
elif x1 == x2:
	print(x1 + q, y1, x2 + q, y2)
elif h != q:
	print(-1)
else:
	print(x1, y2, x2, y1)


(x, y, p, q) = map(int, input().split())
if x == p or y == q:
	if x == p:
		l = abs(q - y)
		if x + l in range(-1000, 1000):
			print(x + l, y, p + l, q)
			exit(0)
		elif x - l in range(-1000, 1000):
			print(x - l, y, p - l, q)
			exit(0)
	else:
		l = abs(p - x)
		if y + l in range(-1000, 1000):
			print(x, y + l, p, q + l)
			exit(0)
		elif y - l in range(-1000, 1000):
			print(x, y - l, p, q - l)
			exit(0)
elif abs(p - x) == abs(q - y):
	print(x, q, p, y)
	exit(0)
print(-1)


(x1, y1, x2, y2) = map(int, input().split())
arr = [x1, y1, x2, y2]
s = set(arr)
if len(s) == 1:
	print('-1')
elif x1 == x2:
	print(str(x1 + abs(y2 - y1)) + ' ' + str(y1) + ' ' + str(x1 + abs(y2 - y1)) + ' ' + str(y2))
elif y1 == y2:
	print(str(x1) + ' ' + str(y1 + abs(x2 - x1)) + ' ' + str(x2) + ' ' + str(y1 + abs(x2 - x1)))
elif abs(y2 - y1) == abs(x2 - x1):
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))
else:
	print('-1')


from sys import stdin, stdout
cin = stdin.readline
cout = stdout.write
mp = lambda : list(map(int, cin().split()))

def chars():
	s = cin()
	return list(s[:len(s) - 1])

def pl(a):
	for val in a:
		cout(str(val) + ' ')
	cout('\n')
(x1, y1, x2, y2) = mp()
if x1 == x2:
	cout(str(x1 + abs(y1 - y2)) + ' ' + str(y1) + ' ' + str(x2 + abs(y1 - y2)) + ' ' + str(y2))
elif y1 == y2:
	cout(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
elif x1 - y1 == x2 - y2:
	if x1 > x2:
		cout(str(x1) + ' ' + str(y1 - abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
	else:
		cout(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 - abs(x1 - x2)))
elif x1 - x2 == y2 - y1:
	if x1 > x2:
		cout(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 - abs(x1 - x2)))
	else:
		cout(str(x1) + ' ' + str(y1 - abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
else:
	cout('-1')


(x1, y1, x2, y2) = map(int, input().split())
if x1 != x2 and y1 != y2:
	if abs(x2 - x1) == abs(y2 - y1):
		print(x1, y2, x2, y1)
	else:
		print(-1)
elif x1 == x2:
	if x1 + abs(y2 - y1) <= 1000:
		other_x = x1 + abs(y2 - y1)
		print(other_x, y1, other_x, y2)
	elif x1 - abs(y2 - y1) <= 1000:
		other_x = x1 - abs(y2 - y1)
		print(other_x, y1, other_x, y2)
	else:
		print(-1)
elif y1 + abs(x2 - x1) <= 1000:
	y = y1 + abs(x2 - x1)
	print(x1, y, x2, y)
elif y1 - abs(x2 - x1) <= 1000:
	y = y1 - abs(x2 - x1)
	print(x1, y, x2, y)
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().split())
x_size = abs(x1 - x2)
y_size = abs(y1 - y2)
if x_size == 0 and y_size == 0:
	print(-1)
elif x_size != 0 and y_size != 0 and (x_size != y_size):
	print(-1)
elif x_size > 0 and y_size > 0:
	print(x1, y2, x2, y1)
elif y_size > 0:
	assert x_size == 0
	assert x1 == x2
	print(x1 + y_size, y1, x1 + y_size, y2)
else:
	assert y_size == 0
	assert y1 == y2
	print(x1, y1 + x_size, x2, y1 + x_size)


(x1, y1, x2, y2) = input().split()
(x1, y1, x2, y2) = [int(x1), int(y1), int(x2), int(y2)]
s1 = abs(x2 - x1)
s2 = abs(y2 - y1)
if s1 != s2 and s1 != 0 and (s2 != 0):
	print('-1')
elif x1 == x2:
	print(s2 + x1, y1, s2 + x2, y2)
elif y1 == y2:
	print(x1, s1 + y1, x2, s1 + y2)
else:
	print(x1, y2, x2, y1)


(a, b, c, d) = list(map(int, input().split()))
e = abs(b - d)
f = abs(a - c)
if a == c:
	e = abs(b - d)
	print(a + e, b, c + e, d)
elif b == d:
	print(a, b + f, c, d + f)
elif e != f:
	print(-1)
else:
	print(a, d, c, b)


from math import *
(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	d = abs(y2 - y1)
	(x3, x4) = (x1 + d, x1 + d)
	print(x3, y1, x4, y2)
elif y1 == y2:
	d = abs(x2 - x1)
	(y3, y4) = (y1 + d, y1 + d)
	print(x1, y3, x2, y4)
else:
	d1 = abs(x2 - x1)
	d2 = abs(y2 - y1)
	if d1 == d2:
		print(x1, y2, x2, y1)
	else:
		print(-1)


(x1, y1, x2, y2) = map(int, input().split())
if x1 - x2 == 0:
	print(str(x1 + abs(y2 - y1)) + ' ' + str(y1) + ' ' + str(x1 + abs(y2 - y1)) + ' ' + str(y2))
elif y1 - y2 == 0:
	print(str(x1) + ' ' + str(y1 + abs(x2 - x1)) + ' ' + str(x2) + ' ' + str(y1 + abs(x2 - x1)))
elif abs(x2 - x1) == abs(y2 - y1):
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))
else:
	print(-1)


(x1, y1, x2, y2) = [int(x) for x in input().split()]
if x1 == x2:
	b = abs(y2 - y1)
	x3 = x1 + b
	x4 = x3
	y3 = y1
	y4 = y2
	print(x3, y3, x4, y4)
if y1 == y2:
	b = abs(x2 - x1)
	y3 = y1 + b
	y4 = y3
	x4 = x2
	x3 = x1
	print(x3, y3, x4, y4)
if x1 != x2 and y1 != y2:
	b = abs(x2 - x1)
	a = abs(y2 - y1)
	if a == b:
		x3 = x1
		x4 = x2
		y3 = y2
		y4 = y1
		print(x3, y3, x4, y4)
	else:
		print('-1')


import os
import sys
from math import *
from io import BytesIO, IOBase

def vsInput():
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

def array():
	return [int(i) for i in input().split()]
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
(x1, y1, x2, y2) = map(int, input().split())
try:
	slope = abs((y2 - y1) / (x2 - x1))
except:
	x = x1 + abs(y2 - y1)
	print(x, y1, x, y2)
	exit()
if slope == 0:
	y = y1 + abs(x2 - x1)
	print(x1, y, x2, y)
elif slope == 1:
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().split())
diff = abs(x2 - x1)
diff1 = abs(y2 - y1)
if x1 != x2 and y1 != y2 and (abs(x2 - x1) != abs(y2 - y1)):
	print(-1)
elif abs(y2 - y1) == 0:
	print(x1, y1 + diff, x2, y2 + diff)
elif abs(x2 - x1) == 0:
	print(x1 + diff1, y1, x2 + diff1, y2)
else:
	print(x1, y2, x2, y1)


import math
(x1, y1, x2, y2) = [int(i) for i in input().split()]
if x1 != x2 and y1 != y2:
	if abs(x1 - x2) == abs(y1 - y2):
		print(x1, y2, x2, y1)
	else:
		print(-1)
elif x1 == x2:
	a = abs(y1 - y2)
	print(x1 + a, y1, x2 + a, y2)
elif y1 == y2:
	a = abs(x1 - x2)
	print(x1, y1 + a, x2, y1 + a)


def sq(x1, y1, x2, y2):
	if x1 == x2:
		print(x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2)
	elif y1 == y2:
		print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
	elif abs(x1 - x2) == abs(y1 - y2):
		print(x1, y2, x2, y1)
	else:
		print(-1)
from sys import stdin, stdout
(x1, y1, x2, y2) = stdin.readline().split()
sq(int(x1), int(y1), int(x2), int(y2))


(x1, y1, x2, y2) = map(int, input().split())
x = abs(x1 - x2)
y = abs(y1 - y2)
(x3, y3, x4, y4, ck) = (0, 0, 0, 0, 0)
if x == 0:
	x3 = y + x1
	y3 = y1
	x4 = x3
	y4 = y2
	ck = 1
elif y == 0:
	x3 = x1
	y3 = x + y1
	x4 = x2
	y4 = y3
	ck = 1
elif x == y:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	ck = 1
if ck == 0:
	print('-1')
else:
	print(x3, y3, x4, y4)


(x_1, y_1, x_2, y_2) = map(int, input().split())
if x_1 == x_2:
	x_1 += abs(y_1 - y_2)
	x_2 += abs(y_1 - y_2)
elif y_1 == y_2:
	y_1 += abs(x_1 - x_2)
	y_2 += abs(x_1 - x_2)
elif abs(x_1 - x_2) == abs(y_1 - y_2):
	f = y_1 < y_2
	d = abs(y_1 - y_2)
	y_1 += d if f else d * -1
	y_2 += d * -1 if f else d
else:
	print(-1)
	exit()
print(x_1, y_1, x_2, y_2)


a = list(input().split(' '))
b = [int(x) for x in a]
if b[0] == b[2]:
	print(b[0] + abs(b[3] - b[1]), b[1], b[2] + abs(b[3] - b[1]), b[3])
elif b[1] == b[3]:
	print(b[0], b[1] + abs(b[2] - b[0]), b[2], b[3] + abs(b[2] - b[0]))
elif abs(b[0] - b[2]) == abs(b[3] - b[1]):
	print(b[0], b[3], b[2], b[1])
else:
	print(-1)


(x1, y1, x2, y2) = input().split()
x1 = int(x1)
y1 = int(y1)
x2 = int(x2)
y2 = int(y2)
x3 = 0
y3 = 0
x4 = 0
y4 = 0
re = 0
if abs(x2 - x1) == abs(y2 - y1):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
if x1 == x2:
	x3 = x1 + abs(y2 - y1)
	y3 = y1
	x4 = x2 + abs(y2 - y1)
	y4 = y2
if y1 == y2:
	y3 = y1 + abs(x2 - x1)
	x3 = x1
	y4 = y2 + abs(x2 - x1)
	x4 = x2
if x3 == 0 and y3 == 0 and (x4 == 0) and (y4 == 0):
	print(-1)
else:
	print(x3, y3, x4, y4)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2 and y1 != y2:
	diff = max(y2, y1) - min(y2, y1)
	print(x1 + diff, y1, x2 + diff, y2, sep=' ')
elif y1 == y2 and x1 != x2:
	diff = max(x2, x1) - min(x1, x2)
	print(x1, y1 + diff, x2, y2 + diff, sep=' ')
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().strip().split(' '))
if x1 == x2:
	print(x1 + max(y2, y1) - min(y2, y1), y1, x1 + max(y2, y1) - min(y2, y1), y2)
elif y1 == y2:
	print(x1, y1 + max(x2, x1) - min(x2, x1), x2, y1 + max(x2, x1) - min(x2, x1))
elif max(x1, x2) - min(x1, x2) == max(y1, y2) - min(y1, y2):
	print(x1, y2, x2, y1)
else:
	print(-1)


test_input = input()
test_input = test_input.split()
x1 = int(test_input[0])
y1 = int(test_input[1])
x2 = int(test_input[2])
y2 = int(test_input[3])
if x1 - x2 == 0:
	x3 = x1 + abs(y2 - y1)
	x4 = x2 + abs(y2 - y1)
	print(str(x3) + ' ' + str(y1) + ' ' + str(x4) + ' ' + str(y2))
elif x1 - x2 != 0 and (abs(y2 - y1) / abs(x2 - x1) == 1 or abs(float(y2 - y1)) / abs(float(x2 - x1)) == float(0)):
	if abs(float(y2 - y1)) / abs(float(x2 - x1)) == float(0):
		y3 = y1 + abs(x2 - x1)
		y4 = y2 + abs(x2 - x1)
		print(str(x1) + ' ' + str(y3) + ' ' + str(x2) + ' ' + str(y4))
	if abs(y2 - y1) / abs(x2 - x1) == 1:
		x3 = x1
		y3 = y2
		x4 = x2
		y4 = y1
		print(str(x3) + ' ' + str(y3) + ' ' + str(x4) + ' ' + str(y4))
else:
	print(str(-1))


from sys import stdin, stdout
cordinates = list(map(int, stdin.readline().split()))
x1 = cordinates[0]
y1 = cordinates[1]
x2 = cordinates[2]
y2 = cordinates[3]
result = False
if x1 == x2:
	side = abs(y1 - y2)
	cordinates = [x1 + side, y1, x2 + side, y2]
	result = True
elif y1 == y2:
	side = abs(x1 - x2)
	cordinates = [x1, y1 + side, x2, y2 + side]
	result = True
elif abs(x2 - x1) == abs(y2 - y1):
	side = abs(x2 - x1)
	cordinates = [x1, y2, x2, y1]
	result = True
elif abs(x2 - x1) != abs(y2 - y1):
	stdout.write('-1')
if result:
	cordinates = list(map(str, cordinates))
	stdout.write(' '.join(cordinates))


a = list(map(int, input().split()))
if abs(a[0] - a[2]) != abs(a[1] - a[3]) and min(abs(a[0] - a[2]), abs(a[1] - a[3])) != 0:
	print(-1)
elif abs(a[0] - a[2]) != 0 and abs(a[1] - a[3]) != 0:
	print(a[0], a[3], a[2], a[1])
elif abs(a[0] - a[2]) != 0 and abs(a[1] - a[3]) == 0:
	print(a[0], a[1] + abs(a[0] - a[2]), a[2], a[3] + abs(a[0] - a[2]))
else:
	print(a[0] + abs(a[1] - a[3]), a[1], a[2] + abs(a[1] - a[3]), a[3])


nn = list(map(int, input().rstrip().split()))
x1 = nn[0]
y1 = nn[1]
x2 = nn[2]
y2 = nn[3]
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2)
elif y1 == y2:
	print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split())
if x1 != x2 and y1 != y2 and (abs(x2 - x1) != abs(y2 - y1)):
	print(-1)
elif x1 == x2:
	print('{0} {1} {2} {3}'.format(x1 + abs(y2 - y1), y1, x2 + abs(y2 - y1), y2))
elif y1 == y2:
	print('{0} {1} {2} {3}'.format(x1, y1 + abs(x2 - x1), x2, y2 + abs(x2 - x1)))
else:
	print('{0} {1} {2} {3}'.format(x1, y2, x2, y1))


(x1, y1, x2, y2) = map(int, input().split())
if y1 == y2:
	d = abs(x2 - x1)
	if y1 + d <= 1000:
		print(x1, y1 + d, x2, y2 + d)
	elif y1 - d >= -1000:
		print(x1, y1 - d, x2, y2 - d)
	else:
		print(-1)
elif x1 == x2:
	d = abs(y2 - y1)
	if x1 + d <= 1000:
		print(x1 + d, y1, x2 + d, y2)
	elif x1 - d >= -1000:
		print(x1 - d, y1, x2 - d, y2)
	else:
		print(-1)
elif abs(x2 - x1) == abs(y1 - y2):
	print(x1, y2, x2, y1)
else:
	print(-1)


value = [int(m) for m in input().split()]
x1 = value[0]
x2 = value[2]
y1 = value[1]
y2 = value[3]
if not (y2 - y1 == 0 or x2 - x1 == 0 or abs(y2 - y1) == abs(x2 - x1)):
	print(-1)
else:
	if y2 - y1 == 0:
		print(str(x1) + ' ' + str(y1 + abs(x2 - x1)) + ' ' + str(x2) + ' ' + str(y2 + abs(x2 - x1)))
	if value[2] - value[0] == 0:
		print(str(x1 + abs(y2 - y1)) + ' ' + str(y1) + ' ' + str(x2 + abs(y2 - y1)) + ' ' + str(y2))
	if abs(value[1] - value[3]) == abs(value[2] - value[0]):
		print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))


import io
import os
import math

def main():
	(x1, y1, x2, y2) = map(int, input().split())
	if x1 == x2:
		print(x1 + abs(y1 - y2), y1, x1 + abs(y1 - y2), y2)
	elif y1 == y2:
		print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
	elif abs(x1 - x2) == abs(y1 - y2):
		print(x1, y2, x2, y1)
	else:
		print(-1)
main()


def main():
	(x1, y1, x2, y2) = list(map(int, input().split()))
	if x1 == x2:
		print(x1 + abs(y2 - y1), y1, x1 + abs(y2 - y1), y2)
	elif y1 == y2:
		print(x1, y1 + abs(x2 - x1), x2, y1 + abs(x2 - x1))
	elif abs(y2 - y1) != abs(x2 - x1):
		print(-1)
	else:
		print(x1, y2, x2, y1)
t = 1
while t != 0:
	main()
	t -= 1


(x0, x1, x2, x3) = map(int, input().split())
if x2 - x0 == 0:
	distance = abs(x3 - x1)
	print(*[x0 + distance, x1, x2 + distance, x3], sep=' ')
elif x3 - x1 == 0:
	distance = abs(x2 - x0)
	print(*[x0, x1 + distance, x2, x3 + distance], sep=' ')
elif abs(x3 - x1) == abs(x2 - x0):
	print(*[x0, x3, x2, x1], sep=' ')
else:
	print(-1)


l = list(map(int, input().split()))
x1 = l[0]
x2 = l[2]
y1 = l[1]
y2 = l[3]
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print('-1')
elif x1 == x2:
	print(x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2, sep=' ')
elif y1 == y2:
	print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2), sep=' ')
else:
	print(x1, y2, x2, y1, sep=' ')


(a, b, c, d) = map(int, input().split(' '))
dis = ((a - c) ** 2 + (b - d) ** 2) ** 0.5
if a == c or b == d:
	if dis - int(dis) == 0:
		if a == c:
			x1 = a
			y1 = b
			x2 = c
			y2 = d
			if a + dis <= 1000:
				x1 += dis
				x2 += dis
			else:
				x1 -= dis
				x2 -= dis
			print(int(x1), b, int(x1), d)
		else:
			x1 = a
			y1 = b
			x2 = c
			y2 = d
			if b + dis <= 1000:
				y1 += dis
				y2 += dis
			else:
				y2 -= dis
				y1 -= dis
			print(a, int(y1), c, int(y2))
	else:
		print(-1)
elif abs(a - c) == abs(d - b):
	print(a, d, c, b)
else:
	print(-1)


from math import sqrt
(x1, y1, x2, y2) = [int(s) for s in input().split()]
d = int(sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2))
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print('-1')
elif x1 == x2:
	print(x1 + d, y1, x2 + d, y2)
elif y1 == y2:
	print(x1, y1 + d, x2, y2 + d)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split())
length = 0
if x1 == x2 or y1 == y2:
	if x1 == x2:
		length = abs(y1 - y2)
		if x1 + length <= 1000:
			print(x1 + length, y1, x1 + length, y2)
		elif x1 - length >= -1000:
			print(x1 - length, y1, x1 - length, y2)
		else:
			print('-1')
	else:
		length = abs(x1 - x2)
		if y1 + length <= 1000:
			print(x1, y1 + length, x2, y2 + length)
		elif y1 - length >= -1000:
			print(x1, y1 - length, x2, y2 - length)
		else:
			print('-1')
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1)
else:
	print('-1')


import math
(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	x3 = x1 + abs(y2 - y1)
	y3 = y1
	x4 = x2 + abs(y2 - y1)
	y4 = y2
	print(x3, y3, x4, y4) if round(math.sqrt((x4 - x1) ** 2 + (y4 - y1) ** 2), 5) == round(math.sqrt(2) * math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2), 5) else print(-1)
elif y1 == y2:
	x3 = x1
	y3 = y1 + abs(x2 - x1)
	x4 = x2
	y4 = y2 + abs(x2 - x1)
	print(x3, y3, x4, y4) if round(math.sqrt((x4 - x1) ** 2 + (y4 - y1) ** 2), 5) == round(math.sqrt(2) * math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2), 5) else print(-1)
else:
	x4 = x2
	y4 = y1
	x3 = x1
	y3 = y2
	print(x3, y3, x4, y4) if round(math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2), 5) == round(math.sqrt(2) * math.sqrt((x3 - x1) ** 2 + (y3 - y1) ** 2), 5) else print(-1)


(x1, y1, x2, y2) = map(int, input().split())
t = abs(x1 - x2)
a = abs(y1 - y2)
if a != t and t and a:
	print(-1)
elif t == 0:
	print(x1 + a, y1, x1 + a, y2)
elif a == 0:
	print(x1, y1 + t, x2, y1 + t)
else:
	print(x1, y2, x2, y1)


from sys import stdin, stdout
input = stdin.readline
(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	x3 = str(x1 + abs(y1 - y2))
	stdout.write(x3 + ' ')
	stdout.write(str(y1) + ' ')
	stdout.write(x3 + ' ')
	stdout.write(str(y2))
elif y1 == y2:
	y3 = str(y1 + abs(x1 - x2))
	stdout.write(str(x1) + ' ')
	stdout.write(y3 + ' ')
	stdout.write(str(x2) + ' ')
	stdout.write(y3)
elif abs(x1 - x2) == abs(y1 - y2):
	stdout.write(str(x1) + ' ' + str(y2) + ' ')
	stdout.write(str(x2) + ' ' + str(y1) + ' ')
else:
	stdout.write('-1')


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

def garden(x1, y, x2, y2):
	a = abs(x1 - x2)
	b = abs(y1 - y2)
	if x1 == x2:
		print(x1 + b, y1, x2 + b, y2)
	elif y1 == y2:
		print(x1, y1 + a, x2, y2 + a)
	elif a != b:
		print(-1)
	else:
		print(x1, y2, x2, y1)
garden(x1, y1, x2, y2)


__author__ = 'myduomilia'
(x1, y1, x2, y2) = list(map(int, input().split()))
b = False
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2)
elif y1 == y2:
	print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split())
diffy = abs(y1 - y2)
diffx = abs(x1 - x2)
if diffx != 0 and diffy != 0 and (diffx != diffy):
	print(-1)
else:
	if diffx != 0 and diffy != 0:
		(x3, y3, x4, y4) = (x1, y2, x2, y1)
	elif diffx != 0:
		(x3, y3, x4, y4) = (x1, y1 + diffx, x2, y2 + diffx)
	else:
		(x3, y3, x4, y4) = (x1 + diffy, y1, x2 + diffy, y2)
	print(x3, y3, x4, y4)


def sad(x1, y1, x2, y2):
	if y1 == y2:
		return [x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2)]
	elif x1 == x2:
		return [x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2]
	elif abs(x1 - x2) != abs(y1 - y2):
		return [-1]
	return [x1, y2, x2, y1]
(X1, Y1, X2, Y2) = [int(i) for i in input().split()]
print(*sad(X1, Y1, X2, Y2))


(x1, y1, x2, y2) = map(int, input().split())
xd = x1 - x2
yd = y1 - y2
if xd != 0 and yd != 0:
	(x3, y3, x4, y4) = (x1, y2, x2, y1)
elif xd != 0:
	(x3, y3) = (x1, y1 + abs(xd))
	(x4, y4) = (x2, y2 + abs(xd))
else:
	(x3, y3) = (x1 + abs(yd), y1)
	(x4, y4) = (x2 + abs(yd), y2)
if xd != 0 and yd != 0 and (abs(xd) != abs(yd)):
	print(-1)
else:
	print(x3, y3, x4, y4)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	temp = abs(y2 - y1) + x1
	print(temp, y1, temp, y2)
elif y1 == y2:
	temp = abs(x2 - x1) + y1
	print(x1, temp, x2, temp)
elif not abs(x1 - x2) == abs(y1 - y2):
	print(-1)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split())
xdif = abs(x2 - x1)
ydif = abs(y2 - y1)
if x1 == x2:
	print(x1 + ydif, y1, x2 + ydif, y2)
elif y1 == y2:
	print(x1, y1 + xdif, x2, y2 + xdif)
elif xdif != ydif:
	print(-1)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = list(map(int, input().rstrip().split(' ')))
xdiff = abs(x1 - x2)
ydiff = abs(y1 - y2)
if xdiff == 0 and ydiff != 0:
	x3 = x1 + ydiff
	y3 = y1
	x4 = x1 + ydiff
	y4 = y2
	print(x3, y3, x4, y4)
elif xdiff != 0 and ydiff == 0:
	x3 = x1
	y3 = y1 + xdiff
	x4 = x2
	y4 = y1 + xdiff
	print(x3, y3, x4, y4)
elif xdiff == ydiff:
	x3 = x1
	x4 = x2
	y3 = y2
	y4 = y1
	print(x3, y3, x4, y4)
else:
	print('-1')


(x1, y1, x2, y2) = map(int, input().split())
newX1 = 0
newY1 = 0
newX2 = 0
newY2 = 0
answer = '-1'
if x1 == x2:
	newX2 = x1 + abs(y1 - y2)
	newX1 = newX2
	newY1 = y1
	newY2 = y2
	answer = str(newX1) + ' ' + str(newY1) + ' ' + str(newX2) + ' ' + str(newY2)
elif y1 == y2:
	newY1 = y1 + abs(x1 - x2)
	newY2 = newY1
	newX1 = x1
	newX2 = x2
	answer = str(newX1) + ' ' + str(newY1) + ' ' + str(newX2) + ' ' + str(newY2)
elif x1 != x2 and y1 != y2 and (abs(x1 - x2) == abs(y1 - y2)):
	newX1 = x1
	newY1 = y2
	newX2 = x2
	newY2 = y1
	answer = str(newX1) + ' ' + str(newY1) + ' ' + str(newX2) + ' ' + str(newY2)
print(answer)


def func(x1, y1, x2, y2):
	if x1 != x2 and y1 != y2:
		x = abs(x1 - x2)
		y = abs(y1 - y2)
		if x != y:
			print(-1)
		else:
			(x3, x4) = (x1, x2)
			(y3, y4) = (y2, y1)
			print(x3, y3, x4, y4)
	elif x1 != x2:
		y = abs(x1 - x2)
		x = y
		(x3, x4) = (x1, x2)
		if y1 + x < 1001:
			y3 = y4 = y1 + x
			print(x3, y3, x4, y4)
		elif y1 - x > -1001:
			y3 = y4 = y1 - x
			print(x3, y3, x4, y4)
		else:
			print(-1)
	elif y1 != y2:
		x = abs(y1 - y2)
		y = x
		(y3, y4) = (y1, y2)
		if x1 + y <= 1001:
			x3 = x4 = x1 + y
			print(x3, y3, x4, y4)
		elif x1 - y > -1001:
			x3 = x4 = x1 - y
			print(x3, y3, x4, y4)
		else:
			print(-1)
	else:
		print(-1)
(x1, y1, x2, y2) = map(int, input().split())
func(x1, y1, x2, y2)


import sys
inf = float('inf')
(mod, MOD) = (1000000007, 998244353)
from math import ceil, floor, log, sqrt, factorial

def get_array():
	return list(map(int, sys.stdin.readline().strip().split()))

def get_ints():
	return map(int, sys.stdin.readline().strip().split())

def input():
	return sys.stdin.readline().strip()
(x1, y1, x2, y2) = get_ints()
if x1 == x2:
	x3 = abs(y2 - y1) + x1
	print(x3, y1, x3, y2)
elif y1 == y2:
	y3 = abs(x2 - x1) + y1
	print(x1, y3, x2, y3)
elif abs(x2 - x1) != abs(y2 - y1):
	print(-1)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = [int(i) for i in input().split()]
x = abs(x1 - x2)
y = abs(y1 - y2)
if x == 0:
	print(x1 + y, y1, x2 + y, y2)
elif y == 0:
	print(x1, y1 + x, x2, y2 + x)
elif x / y == 1:
	print(x1, y2, x2, y1)
else:
	print(-1)


import math
import collections
import bisect
import heapq
import time
import random
import itertools
import sys
(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2 and y1 == y2:
	print(-1)
elif x1 == x2:
	d = abs(y1 - y2)
	print(x1 + d, y1, x2 + d, y2)
elif y1 == y2:
	d = abs(x1 - x2)
	print(x1, y1 + d, x2, y2 + d)
elif abs(x1 - x2) != abs(y1 - y2):
	print(-1)
else:
	d = abs(x1 - x2)
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = list(map(int, input().split()))
(d1, d2) = (abs(x2 - x1), abs(y2 - y1))
if x1 == x2:
	print(x1 + d2, y1, x2 + d2, y2)
elif y1 == y2:
	print(x1, y1 + d1, x2, y2 + d1)
elif d1 == d2:
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = input().split()
x1 = int(x1)
x2 = int(x2)
y2 = int(y2)
y1 = int(y1)
x3 = 0
y3 = 0
x4 = 0
y4 = 0
sz = abs(x2 - x1)
sy = abs(y2 - y1)
sx = max(sz, sy)
if sz == sy:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4, sep=' ')
elif x1 == x2:
	x3 = x1 + sy
	y3 = y1
	x4 = x2 + sy
	y4 = y2
	print(x3, y3, x4, y4, sep=' ')
elif y1 == y2:
	x3 = x1
	y3 = y1 + sx
	x4 = x2
	y4 = y2 + sx
	print(x3, y3, x4, y4, sep=' ')
else:
	print('-1')


(a, b, c, d) = list(map(int, input().split()))
p = abs(a - c)
q = abs(b - d)
if p > 0 and q > 0 and (p != q):
	print(-1)
elif p > 0 and q > 0 and (p == q):
	print(a, d, c, b)
elif a == c:
	print(a + abs(b - d), b, a + abs(b - d), d)
elif b == d:
	print(a, b + abs(a - c), c, d + abs(a - c))


(x1, y1, x2, y2) = list(map(int, input().split()))
sa = abs(x1 - x2)
sb = abs(y1 - y2)
if sa == sb:
	print(*(x1, y2, x2, y1))
elif x1 == x2:
	print(*(x1 + sb, y1, x2 + sb, y2))
elif y1 == y2:
	print(*(x1, y1 + sa, x2, y2 + sa))
else:
	print(-1)


mod = 1000000007
ii = lambda : int(input())
si = lambda : input()
dgl = lambda : list(map(int, input()))
f = lambda : map(int, input().split())
il = lambda : list(map(int, input().split()))
ls = lambda : list(input())
(x1, y1, x2, y2) = f()
l = abs(x1 - x2)
b = abs(y1 - y2)
if x1 == x2:
	print(x1 + b, y1, x2 + b, y2)
elif y1 == y2:
	print(x1, y1 + l, x2, y2 + l)
elif l != b:
	print(-1)
else:
	print(x1, y2, x2, y1)


import sys
import math
xy = [int(x) for x in sys.stdin.readline().split()]
x1 = xy[0]
y1 = xy[1]
x2 = xy[2]
y2 = xy[3]
if x1 == x2:
	print(str(x1 + int(math.fabs(y1 - y2))) + ' ' + str(y1) + ' ' + str(x2 + int(math.fabs(y1 - y2))) + ' ' + str(y2))
elif y1 == y2:
	print(str(x1) + ' ' + str(y1 + int(math.fabs(x1 - x2))) + ' ' + str(x2) + ' ' + str(y2 + int(math.fabs(x1 - x2))))
elif math.fabs(math.fabs(x1 - x2)) == math.fabs(math.fabs(y1 - y2)):
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))
else:
	print(-1)


import sys
import math
import os
(x1, y1, x2, y2) = list(map(int, input().split()))
if x1 != x2 and y1 != y2:
	if abs(x1 - x2) != abs(y1 - y2):
		print(-1)
	else:
		print(x1, y2, x2, y1)
elif x1 == x2:
	print(x1 + abs(y2 - y1), y1, x1 + abs(y2 - y1), y2)
else:
	print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))


inp = str(input()).split()
x1 = int(inp[0])
y1 = int(inp[1])
x2 = int(inp[2])
y2 = int(inp[3])
xabs = abs(x1 - x2)
yabs = abs(y1 - y2)
if x1 != x2 and y1 != y2 and (xabs != yabs):
	print(-1)
elif x1 == x2:
	print('{} {} {} {}'.format(x1 + yabs, y1, x2 + yabs, y2))
elif y1 == y2:
	print('{} {} {} {}'.format(x1, y1 + xabs, x2, y2 + xabs))
else:
	print('{} {} {} {}'.format(x1, y2, x2, y1))


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	x = abs(y2 - y1)
	ls = [x1 + x, y1, x1 + x, y2]
	print(' '.join(map(str, ls)))
elif y1 == y2:
	x = abs(x2 - x1)
	ls = [x1, y1 + x, x2, y2 + x]
	print(' '.join(map(str, ls)))
elif abs(x2 - x1) == abs(y2 - y1):
	ls = [x1, y2, x2, y1]
	print(' '.join(map(str, ls)))
else:
	print(-1)


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
import math

def fact(x):
	if x == 0:
		return 1
	else:
		return x * fact(x - 1)

def lower_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] >= num:
			answer = middle
			end = middle - 1
		else:
			start = middle + 1
	return answer

def upper_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] <= num:
			answer = middle
			start = middle + 1
		else:
			end = middle - 1
	return answer

def abs(x):
	return x if x >= 0 else -x
for t in range(1):
	(x1, y1, x2, y2) = list(map(int, input().split()))
	xd = abs(x2 - x1)
	yd = abs(y2 - y1)
	if (x1 != x2 and y2 != y1) and xd != yd:
		print(-1)
	elif x1 == x2:
		print(x1 + yd, y1, x2 + yd, y2)
	elif y2 == y1:
		print(x1, y1 + xd, x2, y2 + xd)
	else:
		print(x1, y2, x2, y1)


n = list(map(int, input().split()))
x1 = n[0]
y1 = n[1]
x2 = n[2]
y2 = n[3]
Sam_x = x1 == x2
Sam_y = y1 == y2
if Sam_x:
	print(x1 + abs(y1 - y2), end=' ')
	print(y1, end=' ')
	print(x1 + abs(y1 - y2), end=' ')
	print(y2)
elif Sam_y:
	print(x1, end=' ')
	print(y1 + abs(x1 - x2), end=' ')
	print(x2, end=' ')
	print(y1 + abs(x1 - x2))
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, end=' ')
	print(y2, end=' ')
	print(x2, end=' ')
	print(y1)
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().split())
delta_x = abs(x1 - x2)
delta_y = abs(y1 - y2)
if x1 == x2:
	print(x1 + delta_y, y1, x2 + delta_y, y2)
elif y1 == y2:
	print(x1, y1 + delta_x, x2, y2 + delta_x)
elif delta_x / delta_y != 1:
	print(-1)
else:
	print(x1, y2, x2, y1)


(a, b, c, d) = input().split()
a = int(a)
b = int(b)
c = int(c)
d = int(d)
if a == c:
	print(str(abs(b - d) + a) + ' ' + str(b) + ' ' + str(abs(b - d) + c) + ' ' + str(d))
elif b == d:
	print(str(a) + ' ' + str(abs(a - c) + b) + ' ' + str(c) + ' ' + str(abs(a - c) + d))
elif abs(a - c) != abs(b - d):
	print(-1)
else:
	print(str(a) + ' ' + str(d) + ' ' + str(c) + ' ' + str(b))


import sys
input = lambda : sys.stdin.readline().strip('\r\n')
(x1, y1, x2, y2) = map(int, input().split())
a = abs(x1 - x2)
b = abs(y1 - y2)
if a == b:
	print(x1, y2, x2, y1)
elif a == 0:
	print(x1 + b, y1, x2 + b, y2)
elif b == 0:
	print(x1, y1 + a, x2, y2 + a)
else:
	print(-1)


data = input().split()
(X1, Y1, X2, Y2) = (int(data[0]), int(data[1]), int(data[2]), int(data[3]))
(X3, Y3, X4, Y4) = (0, 0, 0, 0)
if X1 != X2 and Y1 != Y2 and (abs(X2 - X1) != abs(Y2 - Y1)):
	print('-1')
	exit
else:
	if X1 == X2:
		(X3, Y3, X4, Y4) = (X1 + abs(Y2 - Y1), Y1, X2 + abs(Y2 - Y1), Y2)
	elif Y1 == Y2:
		(X3, Y3, X4, Y4) = (X1, Y1 + abs(X2 - X1), X2, Y2 + abs(X2 - X1))
	else:
		(X3, Y3, X4, Y4) = (X1, Y2, X2, Y1)
	print(X3, Y3, X4, Y4)


s = input().split()
a = s[0:2]
b = s[2:4]
for i in range(2):
	a[i] = int(a[i])
	b[i] = int(b[i])
if a[0] - b[0] == 0:
	r = abs(int(a[1] - b[1]))
	print(a[0] + r, a[1], b[0] + r, b[1])
elif a[1] - b[1] == 0:
	r = abs(int(a[0] - b[0]))
	print(a[0], a[1] + r, b[0], b[1] + r)
elif abs(a[0] - b[0]) == abs(a[1] - b[1]):
	print(a[0], b[1], b[0], a[1])
else:
	print(-1)


from sys import stdin

def main():
	(x1, y1, x2, y2) = map(int, stdin.readline().strip().split())
	sx = abs(x1 - x2)
	sy = abs(y1 - y2)
	if not sx and sy:
		x1 += sy
		x2 += sy
		print(x1, y1, x2, y2)
	elif sx and (not sy):
		y1 += sx
		y2 += sx
		print(x1, y1, x2, y2)
	elif sx == sy:
		print(x1, y2, x2, y1)
	else:
		print(-1)
main()


arr = input().split()
arr = list(map(int, arr))
if arr[0] - arr[2] != 0:
	slope = (arr[1] - arr[3]) / (arr[0] - arr[2])
else:
	slope = 0.333
arrr = [1, 0, -1, 0.333]
if slope not in arrr:
	print(-1)
elif slope == 1 or slope == -1:
	print(str(arr[0]) + ' ' + str(arr[3]) + ' ' + str(arr[2]) + ' ' + str(arr[1]))
elif slope == 0.333:
	print(str(abs(arr[3] - arr[1]) + arr[0]) + ' ' + str(arr[1]) + ' ' + str(abs(arr[3] - arr[1]) + arr[0]) + ' ' + str(arr[3]))
else:
	print(str(arr[0]) + ' ' + str(abs(arr[2] - arr[0]) + arr[1]) + ' ' + str(arr[2]) + ' ' + str(abs(arr[2] - arr[0]) + arr[1]))


(x1, y1, x2, y2) = map(int, input().split())
a = x2 - x1
b = y2 - y1
flag = False
if abs(a) == abs(b):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
	flag = True
if a == 0 and b != 0 and (flag == False):
	x3 = x1 + abs(b)
	y3 = y1
	x4 = x2 + abs(b)
	y4 = y2
	print(x3, y3, x4, y4)
	flag = True
if b == 0 and a != 0 and (flag == False):
	x3 = x1
	y3 = y1 + abs(a)
	x4 = x2
	y4 = y2 + abs(a)
	print(x3, y3, x4, y4)
	flag = True
if not flag:
	print(-1)


import sys
(x1, y1, x2, y2) = map(int, sys.stdin.readline().split())
if abs(x1 - x2) == 0:
	d = abs(y1 - y2)
	print(x1 + d, y1, x1 + d, y2, sep=' ')
elif abs(y1 - y2) == 0:
	d = abs(x1 - x2)
	print(x1, y1 + d, x2, y2 + d, sep=' ')
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1, sep=' ')
else:
	print('-1')


points = list(map(int, input().split()))
newpoints = None
if points[2] - points[0] == 0:
	distance = abs(points[3] - points[1])
	newpoints = (points[0] + distance, points[1], points[2] + distance, points[3])
elif points[3] - points[1] == 0:
	distance = abs(points[2] - points[0])
	newpoints = (points[0], points[1] + distance, points[2], points[3] + distance)
elif abs(points[3] - points[1]) == abs(points[2] - points[0]):
	newpoints = (points[0], points[3], points[2], points[1])
else:
	newpoints = -1
if type(newpoints) is int:
	print(newpoints)
else:
	print(' '.join((str(x) for x in newpoints)))


(x1, y1, x2, y2) = [int(x) for x in input().split()]
l = abs(x1 - x2)
m = abs(y2 - y1)
if x1 == x2:
	print(x1 + m, y1, x2 + m, y2)
elif y1 == y2:
	print(x1, y1 + l, x2, y2 + l)
elif l != m:
	print(-1)
else:
	print(x1, y2, x2, y1)


import math
coordinates = input().split()
x1 = int(coordinates[0])
y1 = int(coordinates[1])
x2 = int(coordinates[2])
y2 = int(coordinates[3])
if x1 == x2:
	y3 = y1
	y4 = y2
	x3 = x1 + abs(y1 - y2)
	x4 = x2 + abs(y1 - y2)
	print(x3, y3, x4, y4)
elif y1 == y2:
	x3 = x1
	x4 = x2
	y3 = y1 + abs(x1 - x2)
	y4 = y2 + abs(x1 - x2)
	print(x3, y3, x4, y4)
elif abs(x1 - x2) == abs(y1 - y2):
	x3 = x1
	x4 = x2
	y3 = y2
	y4 = y1
	print(x3, y3, x4, y4)
else:
	print(-1)


z = input
mod = 10 ** 9 + 7
from collections import *
from queue import *
from sys import *
from collections import *
from math import *
from heapq import *
from itertools import *
from bisect import *
from collections import Counter as cc
from math import factorial as f

def lcd(xnum1, xnum2):
	return xnum1 * xnum2 // gcd(xnum1, xnum2)

def prime(x):
	p = ceil(x ** 0.5) + 1
	for i in range(2, p):
		if x % i == 0:
			return 0
	return 1
for _ in range(1):
	(a, b, c, d) = map(int, z().split())
	l = abs(a - c)
	m = abs(b - d)
	if l == 0:
		print(a + m, b, c + m, d)
	elif m == 0:
		print(a, b + l, c, d + l)
	elif m != l:
		print(-1)
	else:
		print(a, d, c, b)


s = [int(n) for n in input().split()]
x1 = s[0]
y1 = s[1]
x2 = s[2]
y2 = s[3]
x3 = x4 = y3 = y4 = int()
l = 0
if x1 == x2 and y1 != y2:
	l = 1
elif y1 == y2 and x1 != x2:
	l = 2
elif abs((y1 - y2) / (x1 - x2)) == 1:
	l = 3
else:
	l = 0
	print(-1)
if l == 1:
	p = abs(y1 - y2)
	x3 = x1 + p
	x4 = x1 + p
	y3 = y1
	y4 = y2
	print('{} {} {} {}'.format(x3, y3, x4, y4))
elif l == 2:
	p = abs(x1 - x2)
	x3 = x1
	x4 = x2
	y3 = y1 + p
	y4 = y1 + p
	print('{} {} {} {}'.format(x3, y3, x4, y4))
elif l == 3:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print('{} {} {} {}'.format(x3, y3, x4, y4))


t = input()
temp = t.split()
x1 = int(temp[0])
y1 = int(temp[1])
x2 = int(temp[2])
y2 = int(temp[3])
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	a = abs(y1 - y2)
	x3 = x1 + a
	x4 = x2 + a
	y3 = y1
	y4 = y2
	print(x3, y3, x4, y4)
elif y1 == y2:
	a = abs(x1 - x2)
	x3 = x1
	x4 = x2
	y3 = y1 + a
	y4 = y2 + a
	print(x3, y3, x4, y4)
elif x1 != x2 and y1 != y2:
	a = abs(x1 - x2)
	x3 = x1
	x4 = x2
	y3 = y2
	y4 = y1
	print(x3, y3, x4, y4)


def solution():
	(x1, y1, x2, y2) = map(int, input().split())
	if x1 == x2:
		distance = abs(y1 - y2)
		print(str(x1 + distance) + ' ' + str(y1) + ' ' + str(x2 + distance) + ' ' + str(y2))
		return
	if y1 == y2:
		distance = abs(x1 - x2)
		print(str(x1) + ' ' + str(y1 + distance) + ' ' + str(x2) + ' ' + str(y2 + distance))
		return
	if abs(x1 - x2) == abs(y1 - y2):
		print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))
		return
	print(-1)
solution()


in_line = input().split()
x1 = int(in_line[0])
y1 = int(in_line[1])
x2 = int(in_line[2])
y2 = int(in_line[3])
x3 = y3 = x4 = y4 = 0
if x1 == x2:
	y3 = y1
	y4 = y2
	ydelta = abs(y1 - y2)
	x3 = x1 + ydelta
	x4 = x1 + ydelta
	print('%d %d %d %d' % (x3, y3, x4, y4))
	exit()
if y1 == y2:
	x3 = x1
	x4 = x2
	xdelta = abs(x1 - x2)
	y3 = y1 + xdelta
	y4 = y1 + xdelta
	print('%d %d %d %d' % (x3, y3, x4, y4))
	exit()
dx = abs(x1 - x2)
dy = abs(y1 - y2)
if dx != dy:
	print('-1')
	exit()
x4 = x2
y4 = y1
x3 = x1
y3 = y2
print('%d %d %d %d' % (x3, y3, x4, y4))
exit()


def get_result():
	(x1, y1, x2, y2) = [int(val) for val in input().split()]
	if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
		return -1
	if x1 == x2:
		a = abs(y2 - y1)
		return ' '.join(map(str, [x1 + a, y1, x2 + a, y2]))
	if y1 == y2:
		a = abs(x2 - x1)
		return ' '.join(map(str, [x1, y1 + a, x2, y2 + a]))
	return ' '.join(map(str, [x1, y2, x2, y1]))
print(get_result())


def main():
	(x1, y1, x2, y2) = map(int, input().split())
	x = abs(x1 - x2)
	y = abs(y1 - y2)
	a = max(x, y)
	if x == 0:
		print(x1 + a, y1, x2 + a, y2, sep=' ')
	elif y == 0:
		print(x1, y1 + a, x2, y2 + a, sep=' ')
	elif x != y:
		print(-1)
	elif x != 0 and y != 0:
		print(x1, y2, x2, y1)
	else:
		print(-1)
main()


(x1, y1, x2, y2) = map(int, input().split())
x_dist = abs(x1 - x2)
y_dist = abs(y1 - y2)
if x_dist == 0:
	print(x1 + y_dist, y1, x2 + y_dist, y2)
elif y_dist == 0:
	print(x1, y1 + x_dist, x2, y2 + x_dist)
elif x_dist == y_dist:
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = [int(i) for i in input().split()]
a = abs(x1 - x2)
b = abs(y1 - y2)
if a != b and a != 0 and (b != 0):
	out2 = -1
else:
	if x1 != x2 and y1 != y2:
		out = [x1, y2, x2, y1]
	elif x1 == x2:
		out = [x1 + b, y1, x2 + b, y2]
	elif y1 == y2:
		out = [x1, y1 + a, x2, y2 + a]
	out1 = [str(i) for i in out]
	out2 = ' '.join(out1)
print(out2)


(x1, y1, x2, y2) = map(int, input().split())
if (x1 != x2 and y1 != y2) and abs(x2 - x1) == abs(y2 - y1):
	(x3, y3) = (x1, y2)
	(x4, y4) = (x2, y1)
	print(x3, y3, x4, y4)
elif x1 == x2:
	diff = abs(y2 - y1)
	if x1 + diff <= 1000:
		(x3, y3) = (x1 + diff, y1)
		(x4, y4) = (x1 + diff, y2)
		print(x3, y3, x4, y4)
	elif x1 - diff >= 1000:
		(x3, y3) = (x1 - diff, y1)
		(x4, y4) = (x1 - diff, y2)
		print(x3, y3, x4, y4)
	else:
		print(-1)
elif y1 == y2:
	diff = abs(x2 - x1)
	if y1 + diff <= 1000:
		(x3, y3) = (x1, y1 + diff)
		(x4, y4) = (x2, y1 + diff)
		print(x3, y3, x4, y4)
	elif y1 - diff >= 1000:
		(x3, y3) = (x1, y1 - diff)
		(x4, y4) = (x2, y2 - diff)
		print(x3, y3, x4, y4)
	else:
		print(-1)
else:
	print(-1)


(x1, y1, x2, y2) = [int(x) for x in input().split()]
if x1 == x2 and y1 == y2:
	print(-1)
elif x1 != x2 and y1 != y2:
	if abs(x1 - x2) == abs(y1 - y2):
		print(x1, y2, x2, y1)
	else:
		print('-1')
elif x1 == x2:
	a = abs(y1 - y2)
	print(x1 + a, y1, x2 + a, y2)
else:
	a = abs(x1 - x2)
	print(x1, y1 + a, x2, y2 + a)


(x1, y1, x2, y2) = map(int, input().split())
l = abs(x2 - x1)
m = abs(y2 - y1)
if x1 == x2:
	print(x1 + m, y1, x2 + m, y2)
elif y1 == y2:
	print(x1, y1 + l, x2, y2 + l)
elif l != m:
	print(-1)
else:
	print(x1, y2, x2, y1)


def fun(x1, y1, x2, y2):
	if x1 == x2:
		x3 = x1 + abs(y2 - y1)
		x4 = x3
		y3 = y1
		y4 = y2
	elif y1 == y2:
		x3 = x1
		x4 = x2
		y3 = y1 + abs(x2 - x1)
		y4 = y3
	else:
		slope = abs((y2 - y1) / (x2 - x1))
		if slope == 1:
			x3 = x1
			x4 = x2
			y3 = y2
			y4 = y1
		else:
			print(-1)
			return
	print(x3, y3, x4, y4)
(x1, y1, x2, y2) = list(map(lambda x: int(x), input().split()))
fun(x1, y1, x2, y2)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	edge = abs(y1 - y2)
	x3 = x4 = x1 + edge
	y3 = y1
	y4 = y2
	if not (-1000 <= x3 <= 1000 and -1000 <= x4 <= 1000 and (-1000 <= y3 <= 1000) and (-1000 <= y4 <= 1000)):
		x3 = x4 = x1 - edge
		if not (-1000 <= x3 <= 1000 and -1000 <= x4 <= 1000 and (-1000 <= y3 <= 1000) and (-1000 <= y4 <= 1000)):
			print(-1)
		else:
			print(x3, y3, x4, y4)
	else:
		print(x3, y3, x4, y4)
elif y1 == y2:
	edge = abs(x1 - x2)
	y3 = y4 = y1 + edge
	x3 = x1
	x4 = x2
	if not (-1000 <= x3 <= 1000 and -1000 <= x4 <= 1000 and (-1000 <= y3 <= 1000) and (-1000 <= y4 <= 1000)):
		y3 = y4 = y1 - edge
		if not (-1000 <= x3 <= 1000 and -1000 <= x4 <= 1000 and (-1000 <= y3 <= 1000) and (-1000 <= y4 <= 1000)):
			print(-1)
		else:
			print(x3, y3, x4, y4)
	else:
		print(x3, y3, x4, y4)
else:
	slope = (y1 - y2) / (x1 - x2)
	if slope != 1 and slope != -1:
		print(-1)
	else:
		x3 = x1
		x4 = x2
		y3 = y2
		y4 = y1
		if not (-1000 <= x3 <= 1000 and -1000 <= x4 <= 1000 and (-1000 <= y3 <= 1000) and (-1000 <= y4 <= 1000)):
			print(-1)
		else:
			print(x3, y3, x4, y4)


import sys

def input():
	return sys.stdin.readline().strip()

def iinput():
	return int(input())

def rinput():
	return map(int, sys.stdin.readline().strip().split())

def get_list():
	return list(map(int, sys.stdin.readline().strip().split()))
(x1, y1, x2, y2) = rinput()
if x1 == x2:
	h = max(y1, y2) - min(y1, y2)
	print(x1 + h, y1, x2 + h, y2)
elif y1 == y2:
	h = max(x1, x2) - min(x1, x2)
	print(x1, y1 + h, x2, y2 + h)
elif max(y1, y2) - min(y1, y2) == max(x1, x2) - min(x1, x2):
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().split())
l = abs(x1 - x2)
m = abs(y1 - y2)
r = []
if l == 0:
	x3 = x1 + m
	x4 = x2 + m
	r.append(x3)
	r.append(y1)
	r.append(x4)
	r.append(y2)
	for i in range(len(r)):
		print(r[i], end=' ')
elif m == 0:
	y3 = y1 + l
	y4 = y2 + l
	r.append(x1)
	r.append(y3)
	r.append(x2)
	r.append(y4)
	for i in range(len(r)):
		print(r[i], end=' ')
elif l != m:
	print('-1')
else:
	r.append(x1)
	r.append(y2)
	r.append(x2)
	r.append(y1)
	for i in range(len(r)):
		print(r[i], end=' ')


(x1, y1, x2, y2) = list(map(int, input().split()))
if x1 == x2 and y1 == y2:
	print(-1)
elif x1 == x2 and y1 != y2:
	l = max(y1, y2) - min(y1, y2)
	x = x1
	if x + l >= -1000 and x + l <= 1000:
		print(x + l, y1, x + l, y2)
	elif x - l >= -1000 and x - l <= 1000:
		print(x - l, y1, x - l, y2)
	else:
		print(-1)
elif x1 != x2 and y1 == y2:
	l = max(x1, x2) - min(x1, x2)
	y = y1
	if y + l >= -1000 and y + l <= 1000:
		print(x1, y + l, x2, y + l)
	elif y - l >= -1000 and y - l <= 1000:
		print(x1, y - l, x2, y - l)
	else:
		print(-1)
elif max(x1, x2) - min(x1, x2) == max(y1, y2) - min(y1, y2):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
else:
	print(-1)


import sys, os
from math import sqrt, gcd, ceil, log, floor, sin, pi
from math import factorial as fact
from bisect import bisect, bisect_left
from collections import defaultdict, Counter, deque
from heapq import heapify, heappush, heappop
from itertools import permutations
input = sys.stdin.readline
read = lambda : list(map(int, input().strip().split()))
MOD = 10 ** 9 + 7

def main():
	(a, b, c, d) = read()
	(x, y) = (abs(a - c), abs(b - d))
	if x == 0:
		print(a + y, b, c + y, d)
	elif y == 0:
		print(a, b + x, c, d + x)
	elif x != 0 and y != 0 and (x == y):
		print(a, d, c, b)
	else:
		print(-1)
main()


import sys
from math import *
input = sys.stdin.readline
RI = lambda : [int(x) for x in sys.stdin.readline().strip().split()]
rw = lambda : input().strip().split()
from collections import defaultdict as df
import heapq
infinite = float('inf')
(x1, y1, x2, y2) = RI()
if y2 - y1 == 0:
	d = abs(x2 - x1)
	print(str(x1) + ' ' + str(y1 + d) + ' ' + str(x2) + ' ' + str(y2 + d))
elif x2 - x1 == 0:
	d = abs(y2 - y1)
	print(str(x1 + d) + ' ' + str(y1) + ' ' + str(x2 + d) + ' ' + str(y2))
elif abs(x1 - x2) == abs(y2 - y1):
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))
else:
	print(-1)


a = input().split()
x1 = int(a[0])
y1 = int(a[1])
x2 = int(a[2])
y2 = int(a[3])
dis = int(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** (1 / 2))
p = 0
s = ''
if x1 - x2 == 0:
	s = str(x1 + dis) + ' ' + str(y1) + ' ' + str(x2 + dis) + ' ' + str(y2)
elif y1 - y2 == 0:
	s = str(x1) + ' ' + str(y1 + dis) + ' ' + str(x2) + ' ' + str(y2 + dis)
elif (x1 - x2) / (y1 - y2) == 1 or (x1 - x2) / (y1 - y2) == -1:
	dis = int(((x1 - x2) ** 2 + (y1 - y2) ** 2) ** (1 / 2) / 2 ** (1 / 2))
	if x1 < x2:
		s = str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1)
	else:
		s = str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1)
else:
	p == 6
	print(-1)
if p != 6:
	print(s)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	d = abs(y1 - y2)
	print(x1 + d, y1, x2 + d, y2)
elif y1 == y2:
	d = abs(x1 - x2)
	print(x1, y1 + d, x2, y2 + d)
else:
	k1 = abs(x1 - x2)
	k2 = abs(y1 - y2)
	d = k1 * k1 + k2 * k2
	q = (d // 2) ** (1 / 2)
	if d % 2 == 0 and q == int(q):
		x3 = x1
		y3 = y2
		x4 = x2
		y4 = y1
		s1 = abs(x1 - x3) * abs(x1 - x3) + abs(y1 - y3) * abs(y1 - y3)
		s2 = abs(x1 - x4) * abs(x1 - x4) + abs(y1 - y4) * abs(y1 - y4)
		if s1 == s2:
			print(x3, y3, x4, y4)
		else:
			print(-1)
	else:
		print(-1)


import math
(x1, y1, x2, y2) = [int(x) for x in input().split()]
d = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
if x1 == x2:
	d = int(d)
	print(x1 + d, y1, x2 + d, y2)
elif y1 == y2:
	d = int(d)
	print(x1, y1 + d, x2, y2 + d)
elif abs(x2 - x1) == abs(y2 - y1):
	print(x1, y2, x2, y1)
else:
	print(-1)


(x1, y1, x2, y2) = (int(x) for x in input().split())
if x1 == x2:
	a = abs(y2 - y1)
	print(x1 + a, y1, x2 + a, y2)
	quit()
if y1 == y2:
	a = abs(x1 - x2)
	print(x1, y1 + a, x2, y2 + a)
	quit()
if abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1)
	quit()
print(-1)


(x1, y1, x2, y2) = map(int, input().strip().split(' '))
if y1 == y2:
	p = abs(x1 - x2)
	print(x1, y1 + p, x2, y2 + p, end=' ')
elif x1 == x2:
	p = abs(y1 - y2)
	print(x1 + p, y1, x2 + p, y2, end=' ')
elif abs((y1 - y2) / (x1 - x2)) == 1:
	print(x1, y2, x2, y1, end=' ')
else:
	print(-1)


import math
b = []
a = list(map(int, input().split(' ')))[:4]
if a[0] == a[2]:
	side = abs(a[1] - a[3])
	b.append(a[0] + side)
	b.append(a[1])
	b.append(a[2] + side)
	b.append(a[3])
elif a[1] == a[3]:
	side = abs(a[0] - a[2])
	b.append(a[0])
	b.append(a[1] + side)
	b.append(a[2])
	b.append(a[3] + side)
else:
	b.append(a[0])
	b.append(a[3])
	b.append(a[2])
	b.append(a[1])
if a[0] != a[2] and a[1] != a[3] and (abs(a[0] - a[2]) != abs(a[1] - a[3])):
	print(-1)
else:
	print(*b)


(x1, y1, x2, y2) = map(int, input().split())
(first_x, first_y, sec_x, sec_y) = (0, 0, 0, 0)
if x1 != x2 and y1 != y2:
	if abs(x2 - x1) != abs(y2 - y1):
		print(-1)
	else:
		print(x1, y2, x2, y1)
elif x1 == x2:
	side = abs(y1 - y2)
	print(x1 + side, y1, x2 + side, y2)
elif y1 == y2:
	side = abs(x1 - x2)
	print(x1, y1 + side, x2, y2 + side)
else:
	print(-1)


from sys import stdin, stdout
import math
from itertools import permutations, combinations
from collections import defaultdict
from bisect import bisect_left
from bisect import bisect_right

def L():
	return list(map(int, stdin.readline().split()))

def In():
	return map(int, stdin.readline().split())

def I():
	return int(stdin.readline())
P = 1000000007

def main():
	(x1, y1, x2, y2) = In()
	if x1 == x2:
		s = abs(y1 - y2)
		print(x1 + s, y1, x2 + s, y2)
	elif y1 == y2:
		s = abs(x1 - x2)
		print(x1, y1 + s, x2, y2 + s)
	elif abs(x1 - x2) == abs(y1 - y2):
		print(x1, y2, x2, y1)
	else:
		print(-1)
main()


(x1, y1, x2, y2) = map(int, input().split())
if y1 == y2 and x1 != x2:
	side = abs(x1 - x2)
	(x3, y3) = (x1, y1 + side)
	(x4, y4) = (x2, y2 + side)
	print(x3, y3, x4, y4)
elif x1 == x2 and y1 != y2:
	side = abs(y1 - y2)
	(x3, y3) = (x1 + side, y1)
	(x4, y4) = (x2 + side, y2)
	print(x3, y3, x4, y4)
elif (y1 - y2) / (x1 - x2) == 1 or (y1 - y2) / (x1 - x2) == -1:
	(x3, y3) = (x1, y2)
	(x4, y4) = (x2, y1)
	print(x3, y3, x4, y4)
else:
	print(-1)


string = input('')
coords = string.split(' ')
(x1, y1) = coords[0:2:1]
(x1, y1) = (int(x1), int(y1))
(x2, y2) = coords[2::1]
(x2, y2) = (int(x2), int(y2))
sideLength = 0
if x1 == x2 or y1 == y2:
	result = str(x1 + abs(y1 - y2)) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2 + abs(y1 - y2)) + ' ' + str(y2 + abs(x1 - x2))
	print(result)
	exit()
if abs(x1 - x2) != abs(y1 - y2):
	print('-1')
	exit()
result = str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1)
print(result)


def abs(x):
	if x > 0:
		return x
	else:
		return -x
(x1, y1, x2, y2) = map(int, input('').split())
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(str(x1 + abs(y1 - y2)) + ' ' + str(y1) + ' ' + str(x2 + abs(y1 - y2)) + ' ' + str(y2))
elif y1 == y2:
	print(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
else:
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))


(x1, y1, x2, y2) = [int(i) for i in input().split()]
if x1 != x2 and y1 != y2:
	if abs(x1 - x2) != abs(y1 - y2) or x1 > 1000 or x2 > 1000 or (y1 > 1000) or (y2 > 1000):
		print(-1)
	else:
		print(x1, y2, x2, y1)
elif x1 != x2:
	print(x1, y1 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
elif y1 != y2:
	print(x1 + abs(y1 - y2), y1, x2 + abs(y1 - y2), y2)


from sys import *
from math import *

def main():
	(x1, y1, x2, y2) = list(map(int, input().split()))
	(x3, y3, x4, y4) = [0] * 4
	if x1 == x2:
		d = abs(y1 - y2)
		(x3, y3, x4, y4) = (x1 + d, y1, x2 + d, y2)
		print(x3, y3, x4, y4)
	elif y1 == y2:
		d = abs(x1 - x2)
		(x3, y3, x4, y4) = (x1, y1 + d, x2, y2 + d)
		print(x3, y3, x4, y4)
	elif abs(x1 - x2) == abs(y1 - y2):
		(x3, y3, x4, y4) = (x1, y2, x2, y1)
		print(x3, y3, x4, y4)
	else:
		print(-1)
main()


(x1, y1, x2, y2) = map(int, input().split())
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	x11 = x1 + abs(y1 - y2)
	x22 = x2 + abs(y1 - y2)
	print(x11, y1, x22, y2)
elif y1 == y2:
	y11 = y1 + abs(x1 - x2)
	y22 = y2 + abs(x1 - x2)
	print(x1, y11, x2, y22)
else:
	print(x1, y2, x2, y1)


import math
(x1, y1, x2, y2) = [int(i) for i in input().split()]
if y1 == y2:
	d = math.sqrt(pow(x1 - x2, 2) + pow(y1 - y2, 2))
	print(x1, int(y1 + d), x2, int(y2 + d))
elif x1 == x2:
	d = math.sqrt(pow(x1 - x2, 2) + pow(y1 - y2, 2))
	print(int(x1 + d), y1, int(x2 + d), y2)
elif not (abs((x2 - x1) / (y2 - y1)) == 1 or abs((x1 - x2) / (y1 - y2)) == 1):
	print('-1')
else:
	print(x1, y2, x2, y1)


a = input()
b = a.split()
c = int(b[0])
d = int(b[1])
e = int(b[2])
g = int(b[3])
if c == e:
	print(c + abs(d - g), d, e + abs(d - g), g)
if d == g:
	print(c, d + abs(c - e), e, g + abs(c - e))
if c != e and d != g and (abs(c - e) != abs(d - g)):
	print(-1)
if c != e and d != g and (abs(c - e) == abs(d - g)):
	print(c, g, e, d)


(x1, y1, x2, y2) = input().split(' ')
x1 = int(x1)
y1 = int(y1)
x2 = int(x2)
y2 = int(y2)
if x1 - x2 != 0 and y1 - y2 != 0 and (abs(x1 - x2) != abs(y1 - y2)):
	print('-1')
	exit(0)
side = 0
if x1 - x2 == 0:
	side = abs(y1 - y2)
	print(x1 + side, y1, x2 + side, y2)
elif y1 - y2 == 0:
	side = abs(x1 - x2)
	print(x1, y1 + side, x2, y2 + side)
else:
	print(x1, y2, x2, y1)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	s = abs(y1 - y2)
	print(x1 + s, y1, x1 + s, y2)
elif y1 == y2:
	s = abs(x1 - x2)
	print(x1, y1 + s, x2, y1 + s)
else:
	s = abs(x1 - x2)
	t = abs(y1 - y2)
	if s != t:
		print(-1)
	else:
		print(x1, y2, x2, y1)


x = input().split(' ')
x1 = int(x[0])
x2 = int(x[2])
y1 = int(x[1])
y2 = int(x[3])
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(str(x1 + abs(y1 - y2)) + ' ' + str(y1) + ' ' + str(x2 + abs(y1 - y2)) + ' ' + str(y2))
elif y1 == y2:
	print(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
else:
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))


from math import *
sInt = lambda : int(input())
mInt = lambda : map(int, input().split())
lInt = lambda : list(map(int, input().split()))
(x1, y1, x2, y2) = mInt()
if x1 == x2 and y1 != y2:
	print(x1 + abs(y2 - y1), y1, x1 + abs(y2 - y1), y2)
elif x1 != x2 and y1 == y2:
	print(x1, y2 + abs(x1 - x2), x2, y2 + abs(x1 - x2))
elif x1 != x2 and y1 != y2 and (abs(x2 - x1) == abs(y2 - y1)):
	print(x1, y2, x2, y1)
else:
	print(-1)


s = input().split()
p1 = (int(s[0]), int(s[1]))
p2 = (int(s[2]), int(s[3]))
if p1[0] == p2[0]:
	print(str(p1[0] + abs(p1[1] - p2[1])), s[1], str(p1[0] + abs(p1[1] - p2[1])), s[3])
elif p1[1] == p2[1]:
	print(s[0], str(p1[1] + abs(p1[0] - p2[0])), s[2], str(p1[1] + abs(p1[0] - p2[0])))
elif abs(p1[0] - p2[0]) == abs(p1[1] - p2[1]):
	print(s[0], s[3], s[2], s[1])
else:
	print('-1')


def ii():
	return int(input())

def ss():
	return [x for x in input()]

def si():
	return [int(x) for x in input().split()]

def mi():
	return map(int, input().split())
(a1, a2, b1, b2) = mi()
if a1 == b1:
	if a1 + abs(a2 - b2) <= 1000:
		print(a1 + abs(a2 - b2), a2, a1 + abs(a2 - b2), b2)
	elif a1 - abs(a2 - b2) >= -1000:
		print(a1 - abs(a2 - b2), a2, a1 - abs(a2 - b2), b2)
	else:
		print(-1)
elif a2 == b2:
	if a2 + abs(a1 - b1) <= 1000:
		print(a1, a2 + abs(a1 - b1), b1, a2 + abs(a1 - b1))
	elif a2 - abs(a1 - b1) >= 1000:
		print(a1, a2 - abs(a1 - b1), b1, a2 - abs(a1 - b1))
	else:
		print(-1)
elif abs(a1 - a2) == abs(b1 - b2):
	print(a1, b2, b1, a2)
elif abs(a1 - b1) == abs(a2 - b2):
	print(a1, b2, b1, a2)
else:
	print(-1)


x = list(map(int, input().split()))
x1 = x[0]
y1 = x[1]
x2 = x[2]
y2 = x[3]
x3 = 0
x4 = 0
y3 = 0
y4 = 0
check = False
if x1 == x2:
	x3 = x1 + abs(y1 - y2)
	y3 = y1
	x4 = x3
	y4 = y2
elif y1 == y2:
	x3 = x1
	x4 = x2
	y3 = y1 + abs(x1 - x2)
	y4 = y3
elif abs(x2 - x1) == abs(y2 - y1):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
else:
	check = True
if check:
	print(-1)
else:
	print(x3, y3, x4, y4)


(x1, y1, x2, y2) = [int(i) for i in input().split()]
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(f'{x1 + abs(y1 - y2):d} {y1:d} {x2 + abs(y1 - y2):d} {y2:d}')
elif y1 == y2:
	print(f'{x1:d} {y1 + abs(x1 - x2):d} {x2:d} {y2 + abs(x1 - x2):d}')
else:
	print(f'{x1:d} {y2:d} {x2:d} {y1:d}')


(x1, y1, x2, y2) = list(map(int, input().split()))
if abs(x1 - x2) == abs(y1 - y2):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
	quit()
if x1 == x2:
	jarak = abs(y1 - y2)
	x3 = jarak + x1
	y3 = y1
	x4 = jarak + x2
	y4 = y2
	print(x3, y3, x4, y4)
	quit()
if y1 == y2:
	jarak = abs(x1 - x2)
	x3 = x1
	y3 = jarak + y1
	x4 = x2
	y4 = jarak + y2
	print(x3, y3, x4, y4)
	quit()
if x1 - x2 != y1 - y2:
	print(-1)
	quit()


from math import fabs
a = list(map(int, input().split()))
if a[0] == a[2]:
	b = int(fabs(a[1] - a[3]))
	if a[0] + b <= 1000:
		print(a[0] + b, a[1], a[0] + b, a[3])
	elif a[0] - b >= -1000:
		print(a[0] - b, a[1], a[0] - b, a[3])
	else:
		print(-1)
elif a[1] == a[3]:
	b = int(fabs(a[0] - a[2]))
	if a[1] + b <= 1000:
		print(a[0], a[1] + b, a[2], a[1] + b)
	elif a[1] - b >= -1000:
		print(a[0], a[1] - b, a[2], a[1] - b)
	else:
		print(-1)
elif fabs(a[0] - a[2]) == fabs(a[1] - a[3]):
	print(a[0], a[3], a[2], a[1])
else:
	print(-1)


(x1, y1, x2, y2) = [int(x) for x in input().split()]
a = abs(y1 - y2)
b = abs(x1 - x2)
solution = True
if x1 == x2:
	x3 = x1 + a
	y3 = y1
	x4 = x3
	y4 = y2
elif y1 == y2:
	x3 = x1
	y3 = y1 + b
	x4 = x2
	y4 = y3
elif a == b:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
else:
	solution = False
if solution:
	print(x3, y3, x4, y4)
else:
	print(-1)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	Dist = abs(y1 - y2)
	NewX = x1 + Dist
	print(NewX, y1, NewX, y2)
elif y1 == y2:
	Dist = abs(x1 - x2)
	NewY = y1 + Dist
	print(x1, NewY, x2, NewY)
elif abs(y2 - y1) / abs(x2 - x1) == 1:
	print(x1, y2, x2, y1)
else:
	print(-1)


def pashmak(x1, y1, x2, y2):
	if x1 == x2:
		s = abs(y1 - y2)
		print(x1 + s, y1, x2 + s, y2)
		return
	elif y1 == y2:
		s = abs(x1 - x2)
		print(x1, y1 + s, x2, y2 + s)
		return
	elif abs(x2 - x1) == abs(y2 - y1):
		print(x1, y2, x2, y1)
		return
	else:
		print(-1)
		return
array = list(map(int, input().split(' ')))
pashmak(*array)


def main():
	(x1, y1, x2, y2) = [int(x) for x in input().split()]
	dist = abs(x1 - x2)
	dist = abs(y1 - y2) if not dist else dist
	if x1 != x2 and y1 != y2:
		if abs(y1 - y2) != abs(x1 - x2):
			print('-1')
		else:
			print(x1, y2, x2, y1)
	elif x1 == x2:
		print(x1 + dist, y1, x2 + dist, y2)
	else:
		print(x1, y1 + dist, x2, y2 + dist)
main()


n = [int(num) for num in input().split()]
x = [0, 0, 0, 0]
flag = 1
if n[0] == n[2]:
	d = abs(n[3] - n[1])
	x[1] = n[1]
	x[3] = n[3]
	if d + n[0] < 1001:
		x[0] = n[0] + d
		x[2] = n[0] + d
	elif n[0] - d > -1001:
		x[0] = n[0] - d
		x[2] = n[1] - d
	else:
		flag = 0
elif n[1] == n[3]:
	d = abs(n[2] - n[0])
	x[0] = n[0]
	x[2] = n[2]
	if n[1] + d < 1001:
		x[1] = n[1] + d
		x[3] = n[3] + d
	elif n[1] - d > -1001:
		x[1] = n[1] - d
		x[3] = n[3] - d
	else:
		flag = 0
else:
	x[0] = n[0]
	x[1] = n[3]
	x[2] = n[2]
	x[3] = n[1]
	if abs(n[2] - n[0]) != abs(n[3] - n[1]):
		flag = 0
if flag == 1:
	for i in x:
		print(i, end=' ')
else:
	print(-1)


inp = input()
inp = inp.split()
x1 = int(inp[0])
y1 = int(inp[1])
x2 = int(inp[2])
y2 = int(inp[3])
x_diff = x1 - x2
y_diff = y1 - y2
if x_diff != 0 and y_diff != 0:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
elif x_diff != 0:
	x3 = x1
	y3 = y1 + abs(x_diff)
	x4 = x2
	y4 = y2 + abs(x_diff)
else:
	x3 = x1 + abs(y_diff)
	y3 = y1
	x4 = x2 + abs(y_diff)
	y4 = y2
if x_diff != 0 and y_diff != 0 and (abs(x_diff) != abs(y_diff)):
	print('-1')
else:
	print(str(x3) + ' ' + str(y3) + ' ' + str(x4) + ' ' + str(y4))


def findPosition(x1, y1, x2, y2):
	if x1 != x2 and y1 == y2:
		x3 = x1
		x4 = x2
		y3 = abs(x1 - x2) + y1
		y4 = abs(x1 - x2) + y1
	elif x1 != x2 and y1 != y2:
		x3 = x1
		x4 = x2
		y3 = y2
		y4 = y1
		if abs(x3 - x2) != abs(y2 - y4):
			print(-1)
			return
	elif x1 == x2 and y1 != y2:
		x3 = abs(y2 - y1) + x1
		x4 = abs(y2 - y1) + x1
		y3 = y1
		y4 = y2
	print(x3, y3, x4, y4)
temp = list(map(int, input().rstrip().split()))
x1 = temp[0]
y1 = temp[1]
x2 = temp[2]
y2 = temp[3]
findPosition(x1, y1, x2, y2)


import math
(x1, y1, x2, y2) = map(int, input().split())
(x3, x4, y3, y4) = (0, 0, 0, 0)
angle = 0
sol = -1
sidex = int(abs(x2 - x1))
sidey = int(abs(y2 - y1))
if sidey == 0 and sidex != 0:
	sol = 0
	x3 = x1
	x4 = x2
	y3 = y1 + sidex
	y4 = y2 + sidex
elif sidex == 0 and sidey != 0:
	sol = 0
	x3 = x1 + sidey
	x4 = x2 + sidey
	y3 = y1
	y4 = y2
elif sidex != 0 and abs(sidey / sidex) == 1:
	sol = 0
	x3 = x1
	x4 = x2
	y3 = y2
	y4 = y1
if not (x3 > -1001 and x3 < 1001 or (x4 > -1001 and x4 < 1001) or (y3 > -1001 and y3 < 1001) or (y4 > -1001 and y4 < 1001)):
	sol = -1
if sol != -1:
	print(x3, y3, x4, y4)
else:
	print(sol)


coords = input().split()
x1 = int(coords[0])
y1 = int(coords[1])
x2 = int(coords[2])
y2 = int(coords[3])
if x1 == x2:
	s = abs(y1 - y2)
	x3 = s + x1
	y3 = y1
	x4 = s + x2
	y4 = y2
	print(x3, y3, x4, y4)
elif y1 == y2:
	s = abs(x1 - x2)
	x3 = x1
	y3 = s + y1
	x4 = x2
	y4 = s + y2
	print(x3, y3, x4, y4)
elif abs(x1 - x2) == abs(y1 - y2):
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	print(x3, y3, x4, y4)
else:
	print(-1)


(x, y, z, w) = map(int, input().split())
xx = abs(x - z)
yy = abs(y - w)
if x == z:
	print(x + yy, y, z + yy, w)
elif y == w:
	print(x, y + xx, z, w + xx)
elif xx != yy:
	print(-1)
else:
	print(x, w, z, y)


import math
from collections import defaultdict, Counter, deque
INF = float('inf')

def gcd(a, b):
	while b:
		(a, b) = (b, a % b)
	return a

def isPrime(n):
	if n <= 1:
		return False
	i = 2
	while i ** 2 <= n:
		if n % i == 0:
			return False
		i += 1
	return True

def primeFactor(n):
	if n % 2 == 0:
		return 2
	i = 3
	while i ** 2 <= n:
		if n % i == 0:
			return i
		i += 1
	return n

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

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

def main():
	(x1, y1, x2, y2) = vars()
	if x1 == x2:
		h = abs(y1 - y2)
		print(x1 + h, y1, x2 + h, y2)
	elif y1 == y2:
		h = abs(x1 - x2)
		print(x1, y1 + h, x2, y2 + h)
	else:
		h1 = abs(y2 - y1)
		h2 = abs(x2 - x1)
		if h1 == h2:
			if y2 < y1:
				y3 = y1 - h1
				y4 = y2 + h1
			else:
				y3 = y1 + h1
				y4 = y2 - h1
			print(x1, y3, x2, y4)
		else:
			print(-1)
t = 1
for _ in range(t):
	main()


(x1, y1, x2, y2) = list(map(int, input().split()))
a = x1 - x2
b = y1 - y2
if x1 != x2 and y1 != y2 and (abs(a) != abs(b)):
	print(-1)
elif x1 == x2:
	print(x1 + abs(b), y1, x2 + abs(b), y2, sep=' ')
elif y1 == y2:
	print(x1, y1 + abs(a), x2, y2 + abs(a), sep=' ')
else:
	print(x1, y2, x2, y1, sep=' ')


(x1, y1, x2, y2) = map(int, input().split())
l1 = [x1, y1]
l2 = [x2, y2]
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
elif x1 == x2:
	print(str(x1 + abs(y1 - y2)) + ' ' + str(y1) + ' ' + str(x2 + abs(y1 - y2)) + ' ' + str(y2))
elif y1 == y2:
	print(str(x1) + ' ' + str(y1 + abs(x1 - x2)) + ' ' + str(x2) + ' ' + str(y2 + abs(x1 - x2)))
else:
	print(str(x1) + ' ' + str(y2) + ' ' + str(x2) + ' ' + str(y1))


from collections import Counter
from collections import defaultdict
from collections import deque

def inpNums():
	return map(int, input().split())
(x1, y1, x2, y2) = inpNums()
if x1 == x2:
	sx = abs(y1 - y2)
	print(x1 + sx, y1, x2 + sx, y2)
elif y1 == y2:
	sy = abs(x1 - x2)
	print(x1, y1 + sy, x2, y2 + sy)
elif abs(y1 - y2) == abs(x1 - x2):
	print(x1, y2, x2, y1)
else:
	print(-1)


import sys

def data():
	return sys.stdin.readline().strip()

def sp():
	return map(int, data().split())

def l():
	return list(sp())
temp = l()
x1 = temp[0]
y1 = temp[1]
x2 = temp[2]
y2 = temp[3]
if x1 != x2 and y1 != y2 and (abs(x1 - x2) != abs(y1 - y2)):
	print(-1)
	exit()
elif x1 == x2:
	x3 = x1 + abs(y1 - y2)
	y3 = y1
	x4 = x2 + abs(y1 - y2)
	y4 = y2
	print(x3, y3, x4, y4)
elif y1 == y2:
	x3 = x1
	y3 = y1 + abs(x1 - x2)
	x4 = x2
	y4 = y2 + abs(x1 - x2)
	print(x3, y3, x4, y4)
else:
	print(x1, y2, x2, y1)


import sys
input = sys.stdin.readline

def ceil(x):
	if x != int(x):
		x = int(x) + 1
	return x

def factorial(x, m):
	val = 1
	while x > 0:
		val = val * x % m
		x -= 1
	return val

def swaparr(arr, a, b):
	temp = arr[a]
	arr[a] = arr[b]
	arr[b] = temp

def gcd(a, b):
	if b == 0:
		return a
	return gcd(b, a % b)

def nCr(n, k):
	if k > n - k:
		k = n - k
	res = 1
	for i in range(k):
		res = res * (n - i)
		res = res / (i + 1)
	return int(res)

def upper_bound(a, x, lo=0, hi=None):
	if hi == None:
		hi = len(a)
	while lo < hi:
		mid = (lo + hi) // 2
		if a[mid] < x:
			lo = mid + 1
		else:
			hi = mid
	return lo

def primefs(n):
	primes = {}
	while n % 2 == 0 and n > 0:
		primes[2] = primes.get(2, 0) + 1
		n = n // 2
	for i in range(3, int(n ** 0.5) + 2, 2):
		while n % i == 0 and n > 0:
			primes[i] = primes.get(i, 0) + 1
			n = n // i
	if n > 2:
		primes[n] = primes.get(n, 0) + 1
	return primes

def power(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def swap(a, b):
	temp = a
	a = b
	b = temp
	return (a, b)

def find(x, link):
	p = x
	while p != link[p]:
		p = link[p]
	while x != p:
		nex = link[x]
		link[x] = p
		x = nex
	return p

def union(x, y, link, size):
	x = find(x, link)
	y = find(y, link)
	if size[x] < size[y]:
		(x, y) = swap(x, y)
	if x != y:
		size[x] += size[y]
		link[y] = x

def sieve(n):
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	return prime
MAXN = int(100000.0 + 5)

def spf_sieve():
	spf[1] = 1
	for i in range(2, MAXN):
		spf[i] = i
	for i in range(4, MAXN, 2):
		spf[i] = 2
	for i in range(3, ceil(MAXN ** 0.5), 2):
		if spf[i] == i:
			for j in range(i * i, MAXN, i):
				if spf[j] == j:
					spf[j] = i

def factoriazation(x):
	ret = {}
	while x != 1:
		ret[spf[x]] = ret.get(spf[x], 0) + 1
		x = x // spf[x]
	return ret

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

def float_array():
	return list(map(float, input().strip().split()))

def str_array():
	return input().strip().split()
MOD = int(1000000000.0) + 7
CMOD = 998244353
INF = float('inf')
NINF = -float('inf')
from itertools import permutations

def solve():
	(a, b, c, d) = map(int, input().split())
	if abs(a - c) != 0 and abs(b - d) != 0 and (abs(a - c) != abs(b - d)):
		print(-1)
	elif abs(a - c) == 0:
		print(a + abs(b - d), b, c + abs(b - d), d)
	elif abs(b - d) == 0:
		print(a, b + abs(a - c), c, d + abs(a - c))
	else:
		print(a, d, c, b)
for _ in range(1):
	solve()


l = input().split()
x1 = int(l[0])
y1 = int(l[1])
x2 = int(l[2])
y2 = int(l[3])
if x1 == x2:
	len = abs(y1 - y2)
	x3 = x1 + len
	x4 = x2 + len
	print(x3, y1, x4, y2)
elif y1 == y2:
	len = abs(x1 - x2)
	y3 = y1 + len
	y4 = y2 + len
	print(x1, y3, x2, y4)
elif abs(x1 - x2) == abs(y1 - y2):
	print(x1, y2, x2, y1)
else:
	print('-1')


coordinates = input()
coordinates = coordinates.split(' ')
coordinates = [int(i) for i in coordinates]
x1 = coordinates[0]
y1 = coordinates[1]
x2 = coordinates[2]
y2 = coordinates[3]
ans = ''
if x1 == x2:
	side = abs(y1 - y2)
	x3 = x1 + side
	y3 = y1
	x4 = x2 + side
	y4 = y2
	ans += str(x3) + ' ' + str(y3) + ' ' + str(x4) + ' ' + str(y4)
	print(ans)
elif y1 == y2:
	side = abs(x1 - x2)
	x3 = x1
	y3 = y1 + side
	x4 = x2
	y4 = y2 + side
	ans += str(x3) + ' ' + str(y3) + ' ' + str(x4) + ' ' + str(y4)
	print(ans)
elif abs(x2 - x1) != abs(y2 - y1):
	print(-1)
else:
	x3 = x1
	y3 = y2
	x4 = x2
	y4 = y1
	ans += str(x3) + ' ' + str(y3) + ' ' + str(x4) + ' ' + str(y4)
	print(ans)


(x1, y1, x2, y2) = map(int, input().split())
if x1 == x2:
	x = x1 + abs(y1 - y2)
	print(x, y1, x, y2)
	quit()
if y1 == y2:
	y = y1 + abs(x1 - x2)
	print(x1, y, x2, y)
	quit()
if abs(x1 - x2) != abs(y1 - y2):
	print(-1)
	quit()
print(x1, y2, x2, y1)