LeetCode: 1249-Minimum Remove to Make Valid Parentheses 解題紀錄
Last Updated on 2022-03-15 by Clay
Last Updated on 2022-03-15 by Clay
Last Updated on 2022-03-14 by Clay
最近我將一些私人環境搬遷到 VS Code 上面去了,但是這之中碰到一個小問題:VS Code 預設支援的 Python 語法解析是基於全域環境,而我則習慣在每個不同的 Python 專案中啟用不同的虛擬環境。
Read More »[VS Code] 在專案中啟用 Python 虛擬環境Last Updated on 2022-03-09 by Clay
選擇排序法(selection sort)同樣是最知名的排序演算法之一,也是相當穩定的排序法。不論是最好的狀況(best case)、平均狀況(average case)、還是最糟的狀況(worst case)通通都是 O(n^2) 的時間複雜度。
Read More »[資料結構] 選擇排序法(Selection Sort)Last Updated on 2022-03-09 by Clay
Given the head
of a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list. Return the linked list sorted as well.
Read More »LeetCode: 82-Remove Duplicates from Sorted List II 解題紀錄Last Updated on 2022-03-01 by Clay
Given an integerRead More »LeetCode: 383-Counting Bits 解題紀錄n
, return an arrayans
of lengthn + 1
such that for eachi
(0 <= i <= n
),ans[i]
is the number of1
's in the binary representation ofi
.