第二个。54132不可能。23415------>1进栈,2进栈,2出栈,3进栈,3出栈,4进栈,4出栈,1出栈,5进栈,5出栈23145------>1进栈,2进栈,2出栈,3进栈,3出栈,1出栈,4进栈,4出栈,5进栈,5出栈15432------>1进栈,1出栈,2进栈,2进栈,4进栈,5进栈,5出栈,4出栈,3出栈,2出栈