i am middle building guijava stack i would know if how do i
I am in middle of building a GUI(Java) for a stack. I would like to know if how do I keep the numbers in the stack so it will be calculated. For ex: lets say I push 1 then 2 then I add them I get 3. Now i would like to push 4 and then add that so I get 7.