We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b7da025 commit ff51e87Copy full SHA for ff51e87
best-time-to-buy-and-sell-stock/river20s.py
@@ -19,7 +19,7 @@ def maxProfit(self, prices):
19
max_profit = max(max_profit, (price - min_price))
20
# 최소 가격 갱신
21
min_price = min(min_price, price)
22
- # 최소 이익 갱신 이후 최소 가격 갱신해야 함
+ # 최대 이익(max_profit) 갱신 이후 최소 가격(min_price) 갱신해야 함
23
# 최대 이익 자체는 이미 '산' 주식에 대해 계산해야 하므로
24
# 사는 동시 팔 수 없음
25
0 commit comments