Skip to main content
Sproutern LogoSproutern
InterviewsGamesBlogToolsAbout
Sproutern LogoSproutern
Donate
Sproutern LogoSproutern

Your complete education and career platform. Access real interview experiences, free tools, and comprehensive resources to succeed in your professional journey.

Company

About UsContact UsSuccess StoriesOur MethodologyBlog❀️ Donate

For Students

Find InternshipsScholarshipsCompany ReviewsCareer ToolsFree ResourcesCollege PlacementsSalary Guide

🌍 Study Abroad

Country GuidesπŸ‡©πŸ‡ͺ Study in GermanyπŸ‡ΊπŸ‡Έ Study in USAπŸ‡¬πŸ‡§ Study in UKπŸ‡¨πŸ‡¦ Study in CanadaGPA Converter

Resources

Resume TemplatesCover Letter SamplesInterview Cheat SheetResume CheckerCGPA ConverterIT CertificationsDSA RoadmapInterview QuestionsFAQ

Legal

Privacy PolicyTerms & ConditionsCookie PolicyDisclaimerSitemap Support

Β© 2026 Sproutern. All rights reserved.

β€’

Made with ❀️ for students worldwide

Follow Us:
    ← DSA Roadmap
    πŸ”™
    Topic #11

    Backtracking

    Systematic trial and error. Build solutions incrementally and abandon candidates that fail constraints.

    Time

    Usually exponential O(2^n) or O(n!)

    Space

    O(n) recursion depth

    Problems

    4 must-do

    Key Patterns

    Permutations
    Combinations
    Subsets
    N-Queens
    Sudoku Solver
    Word Search

    πŸ“‹ Must-Do Problems

    #ProblemDifficultyAsked At
    1Subsets
    Medium
    Google
    Amazon
    Meta
    2Permutations
    Medium
    Google
    Microsoft
    Amazon
    3Combination Sum
    Medium
    Amazon
    Google
    Airbnb
    4N-Queens
    Hard
    Google
    Amazon
    Microsoft

    πŸ’‘ Key Concepts

    1.

    Template: choose β†’ explore β†’ un-choose (backtrack)

    2.

    Use a visited array or set to avoid duplicates

    3.

    Pruning: skip invalid states early to reduce time

    4.

    Subsets = combinations without fixed size

    Continue Practicing

    DSA Roadmap DSA Interview Q&A Practice Games