adding and testing memory