# 0674. Longest Continuous Increasing Subsequence ###### tags: `Leetcode` `FaceBook` `Easy` `Sliding Window` Link: https://leetcode.com/problems/longest-continuous-increasing-subsequence/ ## Code ```java= class Solution { public int findLengthOfLCIS(int[] nums) { int ans = 0; int l = 0, r = 1; int count = 0; while(r < nums.length){ if(nums[r]>nums[r-1]) count++; else{ l = r; count = 0; } if(count>ans) ans = count; r++; } return ans+1; } } ```
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up