Write a method that compares two stacks for equality. The

Write a method that compares two stacks for equality. The method takes two stacks as parameters and returns true if they are identical. The stacks should remain unchanged after the function returns to the calling program.