Modify escape and unescape functions using reduce functions