finished implementing stack architecture