Avoid creating global variables 'match' and 'map'

As this is a bad practice. :stuck_out_tongue_winking_eye: 

Thanks. :smiley: