WORKING: decode + format output