Implement minimum procedures of map.hs