看板 Grad-ProbAsk 關於我們 聯絡資訊
1.Write a function to check whether the contents of two stacks have the same number of elements. Neither stack should be changed. 2.Write an algorithm that determines whether a binary tree is complete. 想不太出來要怎麼寫 有高手可以解答嗎~謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 140.116.142.56
FRAXIS:第一題 如果stack只支援push, pop, empty的操作 01/28 16:54
FRAXIS:那前兩個運算一定會改變stack, 只靠第三個運算似乎不能 01/28 16:55
FRAXIS:確認兩個stack相不相同 所以除非知道stack內部實做方式 01/28 16:55
FRAXIS:不然我想應該是辦不到的吧? 01/28 16:56
qazwsxee:可以做到~我等等回~(剛剛打到一半~PCman當機)_ 01/28 17:02
j4ce:高雄大學資管資結! 01/28 22:50