Provide encoding/decoding helpers for all hash sizes.

See comments https://github.com/evoskuil/libbitcoin-explorer/commit/d63ee702db2bf394a294d8354757671e6b8417c2#commitcomment-8866058