@@ -0,0 +1,860 @@
+import java.util.*;%0A%0Apublic class StackPushPopOrder %7B%0A    public boolean isPopOrder(int %5B%5D pushA,int %5B%5D popA) %7B%0A        if(pushA.length%3C=0%7C%7CpopA.length%3C=0)%0A            return false;%0A        Queue%3CInteger%3E queue = new LinkedList%3CInteger%3E();%0A        for(int i=0; i%3CpushA.length; i++)%7B%0A            queue.add(pushA%5Bi%5D);%0A        %7D%0A        Stack%3CInteger%3E stack = new Stack%3CInteger%3E();%0A        for(int i=0; i%3CpopA.length; i++)%7B%0A            if(queue.contains(popA%5Bi%5D))%7B%0A                while(queue.peek()!=popA%5Bi%5D)%0A                %09stack.push(queue.remove());%0A                queue.remove();%0A                continue;%0A            %7D%0A            if(stack.isEmpty())%0A                return false;%0A            if(stack.peek()!=popA%5Bi%5D)%0A                return false;%0A            if(stack.peek()==popA%5Bi%5D)%0A                stack.pop();%0A        %7D%0A        return true;%0A    %7D%0A%7D%0A

Create StackPushPopOrder.java