JobsJob TrackerJob alerts

Saavn ยท 20 questions

All 20Coding 20
  • Longest Valid ParenthesesCoding
  • Possible DecodingsCoding
  • Cash Flow ProblemCoding
  • Check if Binary Tree is BSTCoding
  • Convert Binary Tree to Mirror TreeCoding
  • Add two numbers represented by linked listsCoding
  • Largest Rectangular Area in a HistogramCoding
  • Maximum number of bridgesCoding
  • Celebrity ProblemCoding
  • Find Mother VertexCoding
  • Check if a singly linked list is a palindromeCoding
  • Largest rectangle of 1s with column swappingCoding
  • Boundary Traversal of binary treeCoding
  • Closest pair from two sorted arraysCoding
  • Count distinct elements in every window of size kCoding
  • Longest subsegment of 1s by changing at most k 0sCoding
  • Count negative numbers in a sorted matrixCoding
  • Find the first duplicate in an arrayCoding
  • Subsequence with sum of pairs not divisible by kCoding
  • Check for pair with sum as xCoding
โ† Saavn questions
  1. Interview questions
  2. Saavn
  3. Longest subsegment of 1s by changing at most k 0s
Coding

Longest subsegment of 1s by changing at most k 0s

Filed under Saavn

The question

Find the length of the longest contiguous subsegment of 1s in a binary array by flipping at most k 0s.

No write-up yet. Related questions below have one.

Related Saavn questions

  • Possible Decodings
  • Cash Flow Problem
  • Maximum number of bridges
  • Find Mother Vertex
  • Largest rectangle of 1s with column swapping
โ† Count distinct elements in every window of size kCount negative numbers in a sorted matrix โ†’

Collected from public candidate posts and coding forums. Updated Nov 2026.