'\240`: command not foundClearly you need to clean the code and here is one of the methods to do so. It is just a POB as usual: The character combination \302\240 (U+00A0) is usually found as well when copying code from websites.
However if you are serious about posting code snippets I recommend using gist. Just paste your code or add modifications in the future. You can copy the content from "Embed this gist" which is a script tag you can directly paste in your blog. The code above is coming from nbsp2sp.sh gist.