Punctuations Interview Question

Code to build a hashmap from a string