Start: Jul, 17, 2019 00:00:00
20190717Python程序设计基础培训第三次作业
End: Jul, 21, 2019 00:00:00
Time elapsed:
Time remaining:

Problem_ID: E
Result: Accepted
Time: 48ms
Memory: 25320kB
Author: 15857009836
In contest: 1295

n=int(input())
for i in range(n//7,-1,-1):
	if (n-7*i)%4==0:
		print('4'*((n-7*i)//4)+'7'*i)
		break;
if i==0 and (n-7*i)%4!=0:
	print(-1)