Dynamic Programming

Top-down or Bottom-up

A Harder Problem

  1. For each index, I want to keep track of the longest subsequence at that index.
  2. I will build the subsequence for the next index based on the previous ones.




NYC, fullstack

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Dependency Injection In Spring

An Intro Into The Deep...Links.

Genesis Pure Nutrition Business near Saraland Alabama

Data Loading I: As Sexy As It Sounds

Configuring Load Balancer or Reverse Proxy on RHEL 8

How to Win Engineering Hearts and Minds as a Product Manager

A short story to execute Callable in conventional way and with lambda using ExecutorService in…

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Elliott King

Elliott King

NYC, fullstack

More from Medium

LeetCode 153. Find Minimum in Rotated Sorted Array — Python Solution

Arrays Data Structures Explained

Queue using Stacks —Leetcode

Solving problems with simple yet powerful abstractions in Python, Part 2

A mask (abstraction).