Okay, that made my head hurt. Not because of the math, but because obviously whoever wrote that problem has no clue about chickens. Tell your teacher I said so.
Anyway, IF hens laid eggs at a constant rate unaffected by environment, you would only need to see that in your initial equation you have exactly 2/3 the chickens that you do in the second. Therefore, it would take the hens exactly 2/3 the time to lay the same amount of eggs. In this case, 12 days.
By the way, they threw in that part about the number of chicken coops to make you think that the problem was more difficult than it actually was, and to see if you can filter out extraneous information in order to come to a correct answer.