The compiler says they're undefined because is has to see the functions before you want to use them. So when it gets to line 14, it has no idea of what push() could be. So, you have two choices.
You can 1) move the entire function definitions so that they are before main (not recommended), or 2) place function prototypes before main, letting the compiler know "this is a function; I'll define it later".
The prototype method is what I suggest because it generally looks cleaner, and is easy to understand. Plus, when showing someone complex code, it's a good "road map" of functions (so they don't have to search your code every time they want to know what is returned by pop, for example).
Using a stack, you don't selectively remove data. There's only pop() and push() functions because there's only one spot you ever need to read from or write to - and that's the top of the stack. That's the definition of a stack. If you need to get values other than the top, you should use a different data type.
A criticism: I don't think pop() ought to return anything. This is generally done by a top() function. I'd write a top() function, then do this instead of what your original post does at line 16:
1 2 3 4
while (start) { // Implying that start is not null
cout << top() << endl;
pop();
}
ivo1, great thinking. And ResidentBiscuit is completely right - your program will do whatever you tell it to. For me anyway, that's the joy in programming.