I'm not a mod so what I got to say probably shouldn't be said here
But if I was to post a homework question (I don't do a course though I'm all self taught) I would say at the start of the post that it was a homework question. Also I would state that I had spent x time on the question and looked through the book several times (Which I would have) as well.
That way if it was a homework question at least you have let people know it is a homework question. Also though you have let the people know that you have tried to do to solve the problem yourself and couldn't.
Another thing you could have done is post what you thought may be the answer/solution, then people could point you in the correct direction for a answer.
They don't like homework questions posted as this board is for learning and sharing what you know. I've been to boards were people do post homework, they are no where near as good as this board. It also shows you are not willing to put the hard yards in to learn, so why should someone spend their time answering your homework questions? We are all here to learn, not to answer someone's homework.
Anyway that's my 2 cents where I probably shouldn't have left them