I feel like this must have been addressed somewhere before, but I can't find it.

I had a bit of trouble deciding what to do with an answer the other day and I wanted to get further opinion/ clarification.

The answer has since been edited so I'll just illustrate here rather than link.

<hr/>
*Question code - which isn't working (example)*

    Sub HelloWorld()
        MessageBox "Hello world"
    End Sub

*Answer suggestion*
    
    MessageBox "Hello world"

<hr/>

It's clearly *exactly the same* code that the user has -- not to mention it's a one liner (but that's not really the point)

I flagged it as "Not an answer" because for all intents and purposes, it's not an answer. That said, I was almost certain it would be declined because it looks plenty like an answer. I wondered if I should have flagged as "In need of moderator intervention" and explained that it clearly isn't an answer. I was reluctant to use that option because I feel like "Not an answer" describes the issue well.

From what I've read I can see that we are encouraged to downvote bad answers, but where do you draw the line between someone who has attempted to answer the question and done badly and someone who has simply copy and pasted the same code the user had?

What is the right way to deal with answers like this? Just downvote?