trying to add dynamic mem