Frontend School
FAANG PrepQuestionsPricingSuccess StoriesCommunitySupport
FAANG PrepQuestionsPricingSuccess StoriesCommunitySupport
Frontend School

AI Frontend Interview Simulator for FAANG and product companies.

Support: admin@frontendschool.in

Resources

FAANG Prep GuideInterview QuestionsSuccess Stories

Practice

React Interview QuestionsJavaScript Interview QuestionsMachine Coding RoundFrontend System Design

Product

ProblemsLearnCompaniesTopicsBuy CreditsReferral Program
CommunityPrivacyTermsRefund PolicySupport
  1. Home
  2. Topics
  3. Sliding Window

DSA

Sliding Window Interview Questions for Frontend Engineers

41 data structures and algorithms questions, the kind asked in frontend coding rounds on sliding window, ordered easy to hard. Solve each one in a live IDE and get rubric-based AI feedback.

41
Problems
5
Easy
20
Medium
16
Hard

Easy sliding window problems (5)

easyDSA

Count Substrings with K Distinct Characters

StringSliding WindowHash Map
Livspace
Solve this problem →
easyDSA

Longest Substring with At Most K Distinct Characters

StringSliding WindowHash Map
General
Solve this problem →
easyDSA

Maximum Sum of a Fixed-Length Subarray

ArraysSliding Window
CRED
Solve this problem →
easyDSA

Maximum Vowels in a Fixed-Length Substring

StringSliding WindowArrays
InMobi
Solve this problem →
easyDSA

Maximum Vowels in a Fixed-Length Substring

Sliding WindowString
Microsoft
Solve this problem →

Medium sliding window problems (20)

See all 20
mediumDSA

Consistent Order Segment

ArraysHashingSliding Window
Blinkit
Solve this problem →
mediumDSA

Count Distinct Elements in Sliding Windows

ArraysHashingSliding Window
Freshworks
Solve this problem →
mediumDSA

Count Good Substrings

Sliding WindowFrequency MapString
Freshworks
Solve this problem →
mediumDSA

Count K-Beautiful Substrings

StringSliding WindowHash Map
Snap
Solve this problem →
mediumDSA

Count Subarrays with Bounded Frequencies

ArraysHashingSliding Window
General
Solve this problem →
mediumDSA

Find All Anagrams of a Pattern in a String

StringSliding WindowHash Map
Amazon
Solve this problem →
mediumDSA

Find All Anagrams of a Pattern in Text

StringSliding WindowHash Map
General
Solve this problem →
mediumDSA

Find Anagram Substrings with Wildcard

StringSliding WindowHash Map
Uber
Solve this problem →
mediumDSA

Longest Compliant Substring

StringSliding WindowHash Map
ServiceNow
Solve this problem →
mediumDSA

Longest Diverse Sub-Playlist

ArraysHashingSliding Window
Spotify
Solve this problem →
mediumDSA

Longest Subarray with At Most K Distinct Hotels

Sliding WindowHash MapArrays
OYO
Solve this problem →
mediumDSA

Longest Subarray with Bounded Price Difference

Sliding WindowDequeMonotonic Queue
Meesho
Solve this problem →

More medium sliding window problems

  • Longest Substring After K Replacements
  • Longest Substring with At Most K Character Changes
  • Longest Substring with Balanced Character Counts
  • Max Contiguous Server Block
  • Maximum Average Patient Cohort Score
  • Minimum Subarray with K Distinct Categories
  • Recent Duplicate Transaction Detector
  • Shortest Trending Product Bundle

Hard sliding window problems (16)

See all 16
hardDSA

Count Special Subsegments

Two PointersSliding WindowArrays
Flipkart
Solve this problem →
hardDSA

Count Subarrays with Bounded Difference

Two PointersSliding WindowMonotonic Deque
Pinterest
Solve this problem →
hardDSA

Count Subarrays with K Set Bits in Bitwise OR

Bit ManipulationArraysSubarrays
Meta
Solve this problem →
hardDSA

Diverse Test Sequences

Two PointersSliding WindowHashMap
BrowserStack
Solve this problem →
hardDSA

Lexicographically Smallest Substring with Character Decrements

StringGreedySliding Window
Thoughtworks
Solve this problem →
hardDSA

Longest Subarray with Bounded Distinct Elements and Sum

Two PointersSliding WindowHash Map
Freshworks
Solve this problem →
hardDSA

Longest Subarray with Bounded Distinct Frequencies

ArraysHashingSliding Window
General
Solve this problem →
hardDSA

Minimum Window for K Alternating Pairs

Two PointersSliding WindowString
ServiceNow
Solve this problem →
hardDSA

Minimum Window with Specific Character Frequencies

Sliding WindowHash MapString
CRED
Solve this problem →
hardDSA

Nykaa Transaction Log Processor

QueueDequeSliding Window
Nykaa
Solve this problem →
hardDSA

Optimal Production Segment

Two PointersSliding WindowArrays
Lenskart
Solve this problem →
hardDSA

Optimal Travel Window

Sliding WindowHash MapArrays
MakeMyTrip
Solve this problem →

More hard sliding window problems

  • Shortest Balanced Playlist Segment
  • Shortest Subarray with Minimum Frequency Constraint
  • Shortest Substring with Exactly K Unique Characters and Minimum Frequency Threshold
  • Smallest Subarray with K Diverse and M Limited Characters

Companies that practice sliding window

  • Freshworks3
  • ServiceNow3
  • Livspace2
  • CRED2
  • Spotify2
  • Gupshup2
  • Nykaa2
  • Groww2
  • InMobi1
  • Microsoft1
  • Blinkit1
  • Snap1

Get good at sliding window

Solve problems in a live IDE, get scored on a rubric, and see exactly what to improve.

Start Practicing FreeBrowse all problems