As you can see from the many similar questions, this poorly worded question comes up again and again with just a change of numbers
We must assume that the width is the same for the kitchen and the dining room
let the dining room be x by x
area of dining room = x^2
area of kitchen = 14x
x^2 + 14x = 240
x^2 + 14x - 240 = 0
(x-10)(x+24) = 0
x = 10 or x = -24, which of course would be inadmissible
the dining room is 10 by 10, the kitchen is 10 by 14
and the length of the whole space is 24