Improve test and example for hexadecimal

Modified the tests to:
* be more idiomatic, and return an error when an input is invalid.
* accept both uppercase and lowercase hexadecimal inputs.

Changed the example.go file to have a better annotated solution, that is in my opinion also a better solution.

I'd love feedback on whether or not I contributed my code in the best way, etc.  Basically nitpicking is good :)

If that's all fine, I'll make changes to a number of the other questions that I think need it.