LeetCode
LeetCode 714: Best Time to Buy and Sell Stock with Transaction Fee
·3 mins
LeetCode
Medium
Dynamic-Programming
State-Machine
LeetCode note for Best Time to Buy and Sell Stock with Transaction Fee, rebuilt from the original learning note
LeetCode 3932: Count K-th Roots in a Range
·3 mins
LeetCode
Medium
Binary-Search
Math
LeetCode 3932 note: the answer is floor(r^(1/k)) - floor((l-1)^(1/k)); take roots with integer binary search and count 0 too
LeetCode 3931: Check Adjacent Digit Differences
·1 min
LeetCode
Easy
String
LeetCode 3931 note: check that every pair of adjacent digits differs by at most 2
LeetCode 309: Best Time to Buy and Sell Stock with Cooldown
·3 mins
LeetCode
Medium
Dynamic-Programming
State-Machine
LeetCode note for Best Time to Buy and Sell Stock with Cooldown, rebuilt from the original learning note
LeetCode 198: House Robber
·2 mins
LeetCode
Medium
Dynamic-Programming
LeetCode note for House Robber, rebuilt from the original learning note
LeetCode 188: Best Time to Buy and Sell Stock IV
·4 mins
LeetCode
Hard
Dynamic-Programming
State-Machine
LeetCode note for Best Time to Buy and Sell Stock IV, rebuilt from the original learning note
LeetCode 123: Best Time to Buy and Sell Stock III
·4 mins
LeetCode
Hard
Dynamic-Programming
State-Machine
LeetCode note for Best Time to Buy and Sell Stock III, rebuilt from the original learning note
LeetCode 122: Best Time To Buy And Sell Stock II
·2 mins
LeetCode
Medium
Dynamic-Programming
Greedy
State-Machine
LeetCode note for Best Time To Buy And Sell Stock II, rebuilt from the original learning note
LeetCode 121: Best Time To Buy And Sell Stock
·2 mins
LeetCode
Easy
Dynamic-Programming
State-Machine
LeetCode note for Best Time To Buy And Sell Stock, rebuilt from the original learning note
LeetCode 53: Maximum Subarray
·3 mins
LeetCode
Medium
Dynamic-Programming
Kadane
LeetCode note for Maximum Subarray, rebuilt from the original learning note
LeetCode 413: Arithmetic Slices
·3 mins
LeetCode
Medium
Dynamic-Programming
LeetCode note for Arithmetic Slices, rebuilt from the original learning note
LeetCode 983: Minimum Cost For Tickets
·3 mins
LeetCode
Medium
Dynamic-Programming
LeetCode note for Minimum Cost For Tickets, rebuilt from the original learning note