Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add longest increasing subsequence in JavaScript #2917

Closed
wants to merge 1 commit into from

Conversation

anirudh-kac
Copy link

Fixes #2253

Checklist:

  • 4 space indentation.
  • Coding conventions are followed.
  • Input is taken dynamically.
  • Sample Input / Output is added at the end of file.
  • Logic Documentation (Comments).
  • File names are correct.

Languages Used:

  • JavaScript

Files Added:

  • LIS.js

function lengthOfLIS(nums){

//temporary array to save subsequence length values from that index
var arr = Array(nums.length);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like 2 space indentation, please change to 4 spaces

var arr = Array(nums.length);
//maxLen will store the result
maxLen = 0;
for(var i = 0 ; i< nums.length;i++){
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

space after for


//Examples

a1 = [1,2,3];
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use dynamic inputs

@somya-kapoor
Copy link
Collaborator

Are you working on it?

@MastersAbh
Copy link
Collaborator

Hi @anirudh-kac , I dont see any update from you for over 15 days, so we are closing the PR. in case you want to rework on this, please reach out/ raise a new PR before deadline.

@MastersAbh MastersAbh closed this May 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Longest Increasing Subsequence
3 participants