精華區beta Marginalman 關於我們 聯絡資訊
※ 引述 《DJYOSHITAKA》 之銘言: : class MyCircularDeque: : def insertFront(self, value: int) -> bool: : self.l.insert(0, value) : def insertLast(self, value: int) -> bool: : self.l.append(value) : def deleteFront(self) -> bool: : self.l.pop(0) : def deleteLast(self) -> bool: : self.l.pop() : def getFront(self) -> int: : return self.l[0] : def getRear(self) -> int: : return self.l[-1] : def isEmpty(self) -> bool: : return len(self.l) == 0 : def isFull(self) -> bool: : return len(self.l) == self.k 說到用PY寫哩扣就想起 大學時的肥肥 有次寫不知道什麼sort的題目 我直接 return sort(array) 竟然還給過 當下覺得自己是廢物:( -- https://i.imgur.com/tDUrHwI.gif -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 42.72.245.142 (臺灣) ※ 文章網址: https://www.ptt.cc/bbs/Marginalman/M.1727529008.A.445.html
sustainer123: 寫py的缺點就是有時候自己都不知道為啥能跑 09/28 21:13
nozomizo: sorted 對不起 09/28 21:13
cities516: 還是np.sort()啊 我也忘了 09/28 21:14
sustainer123: .sort() 09/28 21:15
cities516: 哀 PY怎麼這麼難 09/28 21:16
RinNoKareshi: 寶 我可以跟你一起研究PY 09/28 21:17