there are a several issues with the code but for your question as to why it doesn't input into the stack a simple run in gcc debugger shows that that you never get to the inside of

1234

while (isdigit(input))
{
nums.push(input);
}

loop so obviously it isn't getting inserted.
It isnt getting into the the loop becuase of your usage of isdigit. its normally not used the way you are trying to use it. not to mention that you are reading your input in as an int so even if it was a char it would be stored as an int so it doesnt really make sense anyways.