Re: [閒聊] 每日LeetCode已回收

看板Marginalman作者 (廷廷)時間1年前 (2024/02/22 22:35), 編輯推噓5(502)
留言7則, 6人參與, 1年前最新討論串708/719 (看更多)
easy submit了四次才對 我這輩子就這樣了 嗚嗚哇哇哇 997. Find the Town Judge class Solution { public: int findJudge(int n, vector<vector<int>>& trust) { vector<int> trusting(n+1, 0); vector<int> trusted(n+1, 0); for(auto& t:trust){ trusting[t[0]]++; trusted[t[1]]++; } for(int i=1; i<n+1; i++){ if(trusting[i]==0 && trusted[i]==n-1) return i; } return -1; } }; -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 61.230.40.89 (臺灣) ※ 文章網址: https://www.ptt.cc/bbs/Marginalman/M.1708612541.A.43B.html

02/22 22:35, 1年前 , 1F
大師
02/22 22:35, 1F

02/22 22:36, 1年前 , 2F
大施
02/22 22:36, 2F

02/22 22:36, 1年前 , 3F
什麼時候去咕咕嚕賺錢養我
02/22 22:36, 3F

02/22 22:36, 1年前 , 4F
什麼時後能內推我
02/22 22:36, 4F

02/22 22:37, 1年前 , 5F
我two sum submit了40次
02/22 22:37, 5F

02/22 22:37, 1年前 , 6F
我不會two sum
02/22 22:37, 6F

02/22 22:41, 1年前 , 7F
大濕
02/22 22:41, 7F
文章代碼(AID): #1brrkzGx (Marginalman)
討論串 (同標題文章)
文章代碼(AID): #1brrkzGx (Marginalman)