Working code
-------------

Output in form of hex values: