Skip to content
Noteshch-log
AboutSupport
< Back to notes

Browse 4 notes tagged dynamic programming.

#dynamic programming

LeetCode 198: House Robber with take-or-skip rolling states

My House Robber solution, why its p1 and p2 updates work, and a clearer O(n)-time, O(1)-extra-space rolling-state version.

#LeetCode#Blind 75#TypeScript+4
2026-09-15

LeetCode 70: Climbing stairs from repeated recursion to two rolling states

My Climbing Stairs path from a factorial dead end and exponential recursion to an O(n)-time, O(1)-extra-space rolling-state solution.

#LeetCode#Blind 75#TypeScript+4
2026-09-14

LeetCode 152: Why maximum product subarray needs both extremes

My Maximum Product Subarray attempt, the counterexample that broke it, and the final O(n) maximum-and-minimum state solution with an invariant and brute-force checks.

#LeetCode#Blind 75#TypeScript+3
2026-09-11

LeetCode 53: Maximum subarray without rescanning every starting point

My O(n²) backward scan and final O(n) solution, with the distinction between endingHere and best, all-negative inputs, loop invariants, and executable tests.

#LeetCode#Blind 75#TypeScript+3
2026-09-10
Copyright ©2025-2026 hch-log.com. All rights reserved.
Written by Hung-Chih Hsueh ↗ · g3n-data ↗ · All links ↗
Support on Ko-fiAboutPrivacy Policy

Google services settings

Analytics and advertising stay off until you choose.

En中文