<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def format_hex(i, num_bytes=4, prefix='0x'):
 """ Format hexidecimal string from decimal integer value '0000002a' '0x0017' """

    prefix = str(prefix or '')
    i = int(i or 0)
    return prefix + '{0:0{1}x}'.format(i, num_bytes)