We are interested in the dimensions of a certain square. A rectangle has length triple the side of this square and width two units less than the side of this square. If the two areas are equal, what are the square's dimensions (w x h)?

let the square be x by x, so its area = x^2 units^2

length of rectangle = 3x
width of rectangle = x - 2
area of rectangle = 3x(x-2) = 3x^2 - 6x

but 3x^2 - 6x = x^2
2x^2 - 6x = 0
2x(x - 3) = 0
x = 0 or x = 3, but clearly x > 0 or else you have no square

x = 3 <------ the square is 3 by 3

check:
square is 3 by 3 for an area of 9
rectangle = 9 by 1 for an area of 9
my answer is correct.