Transient map

change newM.length to m.length; just to avoid confusion