I feel I should pop my head above the parapets and respond.
This was the question where I added a comment to your answer (10k):
Chris has pretty much covered the reasons I added that friendly comment -
Tut tut...Voting to close and answering the question, you disappoint
me genesis after the nice things I said about you on meta :)
(I was referring to my answer here challenging the perception that only More experienced users get more credit. I used genesis as a great example of someone who has been active on the site for only three months yet has accrued some serious rep in that short period and therefore under the presumption that he's given great advice.)
The question fell into the "Do not ask" category of questions because it was a one line "which one is better..." post and there was pretty much nothing else of merit. It clearly needed to be closed.
Given your very active participation on meta I would expect you to know the minimum quality standards a post should meet and know when to recognise a bad question, which you did by voting to close.
However it surprised me that you felt it was ok to answer this question as well, probably in the hope of gaining rep. The answer you gave wasn't particularly great either and if anything should have been a comment, hence the need to express (nicely) my disappointment in seeing it there.
So, yes the system allows you to do this, but it's morally dubious and as Chris says a wee bit hypocritical.
With regard to your second point, if you know for sure a question is off topic (but does have home somewhere else on SE) and you've voted to close and flagged to migrate then I don't see any harm in providing an answer. You've done your duty in helping to keep SO on-topic.
But if you know a question is way off-topic, not bothered to flag or vote to close, and posted an answer then you will run the risk of being downvoted for not trying to uphold the standards and etiquettes of the site. It can be viewed as encouraging the wrong type of question.
There's nothing personal here, I think it's fantastic that you've gained 12k of rep in just three months, that shows eagerness to help. But if you're gaining that rep by "any means possible" i.e. by indirectly encouraging bad questions through not voting to close and providing answers, then I see that as detrimental to the health of the site.
We need to be sending crystal clear messages about the standards we are trying to uphold and to do that you can't be sitting on the fence and spreading your bets just for the purpose of gaining rep, that just muddies the waters.