problem with stack

is there anyway to compare a stack with variable:

example: if(name_temp==tempstack.top())

for tis, it doesn't works.
Is your stack empty?
no.. both are the same.. as in "Tan" == "Tan"..
but i can't compare in that manner, is there any other ways to compare them?
Can you please post some more of your code as there isn't enough information to be helpful.
i've posted my code on another thread, stack class.
Topic archived. No new replies allowed.