#38898: C++解法之一


lonlon0107 (hello, world)


若是回文,則queue首項恆等於stack末項

由此可得q.front()==s.top()

剩下再照題目做即可。