일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
Tags
- t1
- Python Code
- 컴퓨터의 구조
- 시바견
- DWG
- 밴픽
- 43. Multiply Strings
- Regular Expression
- Class
- 파이썬
- Convert Sorted List to Binary Search Tree
- LeetCode
- concurrency
- kaggle
- Python Implementation
- 운영체제
- Protocol
- 315. Count of Smaller Numbers After Self
- 30. Substring with Concatenation of All Words
- 프로그래머스
- Python
- Substring with Concatenation of All Words
- attribute
- shiba
- Generator
- data science
- iterator
- 109. Convert Sorted List to Binary Search Tree
- Decorator
- 715. Range Module
Archives
- Today
- Total
목록122. Best Time to Buy and Sell Stock II (1)
Scribbling
LeetCode: 122. Best Time to Buy and Sell Stock II
class Solution: def maxProfit(self, prices: List[int]) -> int: profit, prev = 0, prices[0] for i in range(1, len(prices)): if prices[i] >= prev: profit += prices[i] - prev prev = prices[i] return profit
Computer Science/Coding Test
2021. 11. 3. 20:20