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

看板Marginalman作者 (南爹摳打)時間1年前 (2024/02/21 09:38), 編輯推噓0(001)
留言1則, 1人參與, 1年前最新討論串702/719 (看更多)
201. Bitwise AND of Numbers Range 給你left跟right兩個整數 回傳left AND left+1 AND left+2 AND ... AND right C# code: public class Solution { public int RangeBitwiseAnd(int left, int right) { while(right > left) right &= right-1; return right; } } -- (づ′・ω・)づ -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 60.248.96.37 (臺灣) ※ 文章網址: https://www.ptt.cc/bbs/Marginalman/M.1708479522.A.957.html

02/21 13:34, 1年前 , 1F
Bitwise我去死
02/21 13:34, 1F
文章代碼(AID): #1brLGYbN (Marginalman)
討論串 (同標題文章)
文章代碼(AID): #1brLGYbN (Marginalman)