Ruth baked a big cake to sell during the school fair. She sold two-thirds of the pieces. She gave half of the remaining pieces to her friends. She then had 6 pieces left to bring home. Into how many pieces did she cut the cake?

number of pieces --- x

she sold 2/3 of them, leaving (1/3)x
gave half of that , or (1/6)x to friends, leaving her with (1/6)x
but (1/6)x = 6
x = 36

It was cut into 36 pieces