commented and cleaned up the map example