<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: sneha grian</title>
    <description>The latest articles on DEV Community by sneha grian (@snehagrian).</description>
    <link>https://dev.to/snehagrian</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3350071%2Fa4551be2-0aba-47da-9fdd-0176d8690870.png</url>
      <title>DEV Community: sneha grian</title>
      <link>https://dev.to/snehagrian</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/snehagrian"/>
    <language>en</language>
    <item>
      <title>I Built ProofMap Because Recruiters Don’t Trust Resumes Anymore</title>
      <dc:creator>sneha grian</dc:creator>
      <pubDate>Fri, 06 Mar 2026 22:51:48 +0000</pubDate>
      <link>https://dev.to/snehagrian/i-built-proofmap-because-recruiters-dont-trust-resumes-anymore-4m0b</link>
      <guid>https://dev.to/snehagrian/i-built-proofmap-because-recruiters-dont-trust-resumes-anymore-4m0b</guid>
      <description>&lt;p&gt;The developer job market right now is… chaotic.&lt;/p&gt;

&lt;p&gt;Hundreds of applicants.&lt;/p&gt;

&lt;p&gt;Everyone listing the same stack.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Python
React
Node.js
Docker
AWS
Microservices
CI/CD
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Scroll through enough resumes and they start looking identical.&lt;/p&gt;

&lt;p&gt;And honestly, I kept wondering something.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How do hiring managers actually filter developers anymore?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Like seriously.&lt;/p&gt;

&lt;p&gt;If everyone lists the same technologies…&lt;br&gt;
how do you figure out &lt;strong&gt;who actually built something with them?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;That question stuck with me for a while.&lt;/p&gt;

&lt;p&gt;And that curiosity eventually turned into a project I call &lt;strong&gt;ProofMap&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://proofmap.snehagrian.dev" rel="noopener noreferrer"&gt;https://proofmap.snehagrian.dev&lt;/a&gt;&lt;br&gt;
👉 &lt;a href="https://github.com/snehagrian/proofmap" rel="noopener noreferrer"&gt;https://github.com/snehagrian/proofmap&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fee9lo8igdtjmv8dx6f0w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fee9lo8igdtjmv8dx6f0w.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;But the idea didn’t appear randomly.&lt;/p&gt;


&lt;h1&gt;
  
  
  The Moment That Made Me Think About This
&lt;/h1&gt;

&lt;p&gt;During one of my recruiter conversations, something interesting came up.&lt;/p&gt;

&lt;p&gt;The recruiter explained something that made a lot of sense.&lt;/p&gt;

&lt;p&gt;They said in today’s hiring environment, resumes alone are not always enough.&lt;/p&gt;

&lt;p&gt;Not because resumes are useless.&lt;/p&gt;

&lt;p&gt;But because &lt;strong&gt;so many candidates apply&lt;/strong&gt;, and filtering them becomes extremely difficult.&lt;/p&gt;

&lt;p&gt;And there’s another complication.&lt;/p&gt;

&lt;p&gt;A lot of engineers who work in companies &lt;strong&gt;can’t publicly share the projects they worked on&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;If you’ve worked in corporate environments you already know why.&lt;/p&gt;

&lt;p&gt;Most production work is protected by:&lt;/p&gt;

&lt;p&gt;• company IP&lt;br&gt;
• licensing restrictions&lt;br&gt;
• internal systems&lt;br&gt;
• NDAs&lt;/p&gt;

&lt;p&gt;So even if someone worked on something complex, they might not be able to show it publicly.&lt;/p&gt;

&lt;p&gt;Which creates an interesting situation.&lt;/p&gt;

&lt;p&gt;The recruiter explained that when hiring managers want an &lt;strong&gt;extra signal&lt;/strong&gt;, they often check something else.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GitHub.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Not as a replacement for experience.&lt;/p&gt;

&lt;p&gt;But as a way to see:&lt;/p&gt;

&lt;p&gt;• how someone builds things&lt;br&gt;
• how they structure projects&lt;br&gt;
• whether they experiment with technologies&lt;br&gt;
• whether their listed skills show up in real work&lt;/p&gt;

&lt;p&gt;Basically:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Do the skills on the resume actually appear somewhere in their work?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That thought stayed with me.&lt;/p&gt;


&lt;h1&gt;
  
  
  The Curiosity That Started This Project
&lt;/h1&gt;

&lt;p&gt;After that conversation I kept thinking about something.&lt;/p&gt;

&lt;p&gt;What if there was a way to automatically answer this question:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Do my GitHub projects actually support my resume?
Which skills are proven?
Which ones are missing proof?
How can I improve that?
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Not manually.&lt;/p&gt;

&lt;p&gt;Automatically.&lt;/p&gt;

&lt;p&gt;So I started building something that connects &lt;strong&gt;two things developers already have&lt;/strong&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Resume Skills
+
GitHub Repositories
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That project became &lt;strong&gt;ProofMap&lt;/strong&gt;.&lt;/p&gt;




&lt;h1&gt;
  
  
  What ProofMap Actually Does
&lt;/h1&gt;

&lt;p&gt;ProofMap analyzes your GitHub repositories and tries to answer one simple question.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How much of your resume is actually supported by your GitHub projects?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The first thing it generates is something called a &lt;strong&gt;Skill Readiness Score&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Example output:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9fwi5q1bi0et78co16id.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9fwi5q1bi0et78co16id.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This basically means:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Around half of the skills listed in the resume appear in GitHub projects.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The rest might not have visible proof yet.&lt;/p&gt;




&lt;h1&gt;
  
  
  Step 1 — Detect Skills That Exist in Your Code
&lt;/h1&gt;

&lt;p&gt;The system scans GitHub repositories and extracts signals like:&lt;/p&gt;

&lt;p&gt;• programming languages&lt;br&gt;
• dependency files&lt;br&gt;
• frameworks&lt;br&gt;
• repository structure&lt;br&gt;
• project patterns&lt;/p&gt;

&lt;p&gt;Then it builds a list of &lt;strong&gt;skills detected in your repositories&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Skills Present

React
Node.js
REST APIs
JavaScript
TypeScript
MySQL
Python
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These are labeled &lt;strong&gt;Skills Present (Proven)&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Meaning the technologies actually appear in your projects.&lt;/p&gt;




&lt;h1&gt;
  
  
  Step 2 — Detect Skills That Are Missing
&lt;/h1&gt;

&lt;p&gt;Next, the system compares:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Resume Skills
vs
GitHub Evidence
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then it highlights the skills that &lt;strong&gt;don’t appear in repositories yet&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Skills Not Present

AWS
Jenkins
CI/CD
React Native
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This doesn’t mean the developer doesn’t know these skills.&lt;/p&gt;

&lt;p&gt;It simply means:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;GitHub doesn’t currently show proof for them.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And that’s where things get interesting.&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6jj6w5sikwt6wj8124ph.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6jj6w5sikwt6wj8124ph.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Step 3 — Click a Missing Skill → Generate an AI Roadmap
&lt;/h1&gt;

&lt;p&gt;If you click a missing skill, the platform generates &lt;strong&gt;AI-powered project ideas&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;For example, selecting &lt;strong&gt;Jenkins&lt;/strong&gt; might generate suggestions like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Continuous Integration Pipeline
Multi-Branch Pipeline Project
Jenkins Plugin Development
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It also suggests what your GitHub project should include:&lt;/p&gt;

&lt;p&gt;• pipeline configuration&lt;br&gt;
• automated testing&lt;br&gt;
• deployment workflows&lt;/p&gt;

&lt;p&gt;Now you’re not just learning randomly.&lt;/p&gt;

&lt;p&gt;You’re building &lt;strong&gt;projects that prove the skill.&lt;/strong&gt;&lt;/p&gt;


&lt;h1&gt;
  
  
  Step 4 — Sometimes You Don’t Need a New Project
&lt;/h1&gt;

&lt;p&gt;One thing I wanted the system to do was avoid suggesting &lt;strong&gt;random tutorial projects&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Sometimes the best way to learn something new is to &lt;strong&gt;upgrade an existing project&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;So the AI analyzes your repositories and suggests things like:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Add Docker containerization to your Node.js API.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;or&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Implement CI/CD pipeline automation for your current repository.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Instead of starting from scratch, you &lt;strong&gt;improve what you already built&lt;/strong&gt;.&lt;/p&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpwszkw2gre0vej37metw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpwszkw2gre0vej37metw.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h1&gt;
  
  
  Step 5 — If the Skill Doesn’t Fit Your Existing Projects
&lt;/h1&gt;

&lt;p&gt;If a missing skill doesn’t match your current repositories, the AI suggests &lt;strong&gt;new project ideas&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Example suggestions:&lt;/p&gt;

&lt;p&gt;For &lt;strong&gt;AWS&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Serverless Web Application using AWS Lambda
Data Pipeline using Amazon Redshift
Infrastructure as Code using CloudFormation
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For &lt;strong&gt;React Native&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Mobile Task Manager
Weather Application
Fitness Tracking App
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These are designed to become &lt;strong&gt;GitHub-ready portfolio projects&lt;/strong&gt;.&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiq1y9siyb2xaqn93jqv3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiq1y9siyb2xaqn93jqv3.png" alt=" " width="800" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Under the Hood
&lt;/h1&gt;

&lt;p&gt;The system follows a pretty straightforward pipeline.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;1. Fetch GitHub repositories
2. Detect technologies used
3. Normalize skills
4. Compare with resume skills
5. Identify missing skills
6. Generate AI improvement plans
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The key part is giving the AI &lt;strong&gt;context&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;It sees:&lt;/p&gt;

&lt;p&gt;• the developer’s repositories&lt;br&gt;
• the technologies used&lt;br&gt;
• the missing skills&lt;/p&gt;

&lt;p&gt;Which helps generate &lt;strong&gt;more relevant suggestions&lt;/strong&gt;.&lt;/p&gt;




&lt;h1&gt;
  
  
  Why I Built This
&lt;/h1&gt;

&lt;p&gt;Developer hiring today is very different from a few years ago.&lt;/p&gt;

&lt;p&gt;Recruiters and hiring managers look for signals like:&lt;/p&gt;

&lt;p&gt;• real projects&lt;br&gt;
• curiosity&lt;br&gt;
• technical initiative&lt;br&gt;
• problem solving&lt;/p&gt;

&lt;p&gt;Not just a list of keywords.&lt;/p&gt;

&lt;p&gt;ProofMap tries to answer a simple question.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Does your GitHub support the skills on your resume?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;And if the answer is &lt;strong&gt;not yet&lt;/strong&gt;…&lt;/p&gt;

&lt;p&gt;It helps you fix that.&lt;/p&gt;




&lt;h1&gt;
  
  
  Final Thought
&lt;/h1&gt;

&lt;p&gt;Resumes show &lt;strong&gt;what you claim&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;GitHub shows &lt;strong&gt;what you build&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;ProofMap tries to connect the two.&lt;/p&gt;

&lt;p&gt;And honestly…&lt;/p&gt;

&lt;p&gt;The whole idea started with curiosity.&lt;/p&gt;

&lt;p&gt;How do hiring managers actually filter developers today?&lt;/p&gt;

&lt;p&gt;That question turned into a project.&lt;/p&gt;

&lt;p&gt;And now I’m curious what others think.&lt;/p&gt;

</description>
      <category>career</category>
      <category>opensource</category>
      <category>showdev</category>
      <category>sideprojects</category>
    </item>
    <item>
      <title>Sliding Window: A Simple Yet Powerful Technique</title>
      <dc:creator>sneha grian</dc:creator>
      <pubDate>Sun, 13 Jul 2025 08:45:03 +0000</pubDate>
      <link>https://dev.to/snehagrian/sliding-window-a-simple-yet-powerful-technique-16hj</link>
      <guid>https://dev.to/snehagrian/sliding-window-a-simple-yet-powerful-technique-16hj</guid>
      <description>&lt;p&gt;Sliding window is one of those techniques that once you get it, you’ll start spotting it everywhere. It’s a go-to tool for solving problems involving subarrays, substrings, or continuous sequences and can turn an O(n²) brute-force problem into a sleek O(n) solution. Let’s dive in! &lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;What is Sliding Window?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A sliding window helps you iterate through a series of elements in segments. It takes in each element one by one to check a condition, and removes elements when the condition is no longer met.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;How Does It Work?&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;The window moves from left to right.&lt;/li&gt;
&lt;li&gt;Each element is taken into the window to check if it satisfies a specific condition.&lt;/li&gt;
&lt;li&gt;We use two pointers, usually named l (left) and r (right).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Step-by-Step Explanation:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;1. Initialize the two pointers:&lt;/em&gt;&lt;br&gt;
 Start with both l and r at the beginning of the array or string.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;2. Expand the window:&lt;/em&gt;&lt;br&gt;
 While the condition is not yet satisfied, move the r pointer forward to increase the window size.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;3. Check the condition:&lt;/em&gt; &lt;br&gt;
As you include new elements, check if the current window meets the required condition (e.g., sum ≤ target, valid substring, etc.).&lt;/p&gt;

&lt;p&gt;&lt;em&gt;4. Shrink the window if needed:&lt;/em&gt;&lt;br&gt;
If the condition fails, move the l pointer forward to reduce the window size and try to regain a valid window.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Imagine a sliding window: &lt;em&gt;l is the left blade, and r is the right blade.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;If we keep one side of the window constant (say, l), and move the other side (r), the window expands; this is how the sliding window works:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkfmugvxzz0tna1jjcxi4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkfmugvxzz0tna1jjcxi4.png" alt="Sliding window image 1" width="800" height="657"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;When the condition is not satisfied, we change the position of l to the next element. This marks the starting of the new window, and we check through elements using both pointers to find a new valid window.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F02goh9k75mwgree3k18y.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F02goh9k75mwgree3k18y.png" alt="Sliding window image 2" width="800" height="821"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Moving l helps reduce the window size.&lt;/li&gt;
&lt;li&gt;Moving r helps determine the window's right boundary.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Why Do We Use Sliding Window?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Sliding windows are usually used to return a group of elements when our required output is a maximum value, sum, or any condition based on grouping.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The sliding window method helps us to:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Find the output by performing operations on a group of elements stored in a window.&lt;/p&gt;

&lt;p&gt;Segment the list into all possible groups and check for the required condition.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;💡 Key Benefits:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Makes the process easier by reducing time complexity.&lt;/li&gt;
&lt;li&gt;We don’t need to check the already-checked groups again.&lt;/li&gt;
&lt;li&gt;Efficient in problems where we need to slide over input and check conditions dynamically.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;LeetCode Example:&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Let’s see how sliding window logic can solve one of the most asked interview question.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Longest Repeating Character Replacement: &lt;em&gt;(Leetcode no.3)&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Given a string s and an integer k, find the length of the longest substring where you can replace at most k characters to make all characters the same.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Example&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Input: s = "AABABB", k = 2&lt;br&gt;
We want the longest substring where we can replace at most 2 characters to make all characters the same.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step-by-Step Logic&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We apply the rule:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;window size - max frequency ≤ k&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Where:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;window size = r - l + 1&lt;/li&gt;
&lt;li&gt;max frequency = most repeated character in current window&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;If true:&lt;br&gt;
     We can replace the remaining characters → Expand window&lt;br&gt;
If false:&lt;br&gt;
     Too many replacements needed → Shrink window from the left&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8khl0mj3os5hkynqkw6q.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8khl0mj3os5hkynqkw6q.png" alt="Sliding window image 3" width="800" height="800"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Walkthrough:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Best window = "AABAB"&lt;br&gt;
Max freq = 3 (A)&lt;br&gt;
Replacements needed = 5 - 3 = 2&lt;br&gt;
✅ 2 ≤ k → valid window&lt;br&gt;
Result = 5&lt;/p&gt;

&lt;p&gt;This is a classic sliding window problem:&lt;/p&gt;

&lt;p&gt;📌 &lt;em&gt;Expand → Check Condition → Shrink if needed → Track max&lt;/em&gt;&lt;/p&gt;

</description>
      <category>algorithms</category>
      <category>beginners</category>
      <category>datastructures</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
