First, let's move combine like terms:
-5y + 8y = 6 + 2 -12.
3y = -4.
y = -4/3
You apply the sum of interior angles formula ie. (n-2)180. n=number of sides
since a pentagon has 5 sides it will be (5-2)180=540.
now add everything. x-5+x-6+2x-7+x+2x-2=540.
Solve for x: 7x-20=540
7x=540+20
7x=560
x=560/7
x=80
The perimeter is 24.
Remember finding perimeter is always adding, so add 5 two times for the sides do the shape, do the same for 7, then you get your answer. Hope this helps!