Longest Continuous Increasing Subsequence Problem
Longest Continuous Increasing Subsequence Problem — ExecCode Easy DSA Practice
Solve the Longest Continuous Increasing Subsequence problem on ExecCode. Free online easy DSA practice in Arrays - Logic Building. Write and run code in Java, C++, Python — no signup required to run.
Problem description
Description You are given an unsorted array of integers nums, return the length of the longest continuous increasing subsequence (i.e. Your task is to subarray). The subsequence must be strictly increasing. A continuous increasing subsequence is defined by two indices l and r (l < r) such that it is [nums[l], nums[l + 1], ..., nums[r - 1], nums[r]] and for each l <= i < r, nums[i] < nums[i + 1]. Return the required answer exactly as shown in the examples.
Examples
Input {"nums": [1, 3, 5, 4, 7]}; Output 3. Input {"nums": [2, 2, 2, 2, 2]}; Output 1
Constraints
1 <= nums.length <= 10^4 -10^9 <= nums[i] <= 10^9
Practice Longest Continuous Increasing Subsequence free on ExecCode. Browse DSA problems, topic map, and placement guides.