/Longest-Increasing-Subsequence-DP

Given an array or list of n integers, we need to find the longest increasing subsequence. The array could include positive and negative integers.

Primary LanguageC++

Longest Increasing Subsequence Dynamic Programming

Problem Statement

Given an array or list of n integers, we need to find the longest increasing subsequence. The array could include positive and negative integers.

Approach

The algorithm to solve the problem has been implemented in three ways:

  • recursive
  • top-down
  • bottom-up (Dynamic Programming)

Time Complexity

The time complexity of the dynamic programming solution is: O(N^2)

Directory Structure

📦Longest-Increasing-Subsequence-DP
┣ 📜main.cpp
┗ 📜README.md