Skip to content

yssvi72/DSA

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

668 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DSA - Important Questions with C++ Solutions

Welcome to the Data Structures and Algorithms - Important Questions repository! 🚀 This collection is a carefully curated list of crucial questions covering a wide range of DSA topics, with solutions provided in C++.

Tips to Consider If input array is sorted then - Binary search - Two pointers

If asked for all permutations/subsets then - Backtracking

If given a tree then - DFS - BFS

If given a graph then - DFS - BFS

If given a linked list then - Two pointers

If recursion is banned then - Stack

If must solve in-place then - Swap corresponding values - Store one or more different values in the same pointer

If asked for maximum/minumum subarray/subset/options then - Dynamic programming

If asked for top/least K items then - Heap

If asked for common strings then - Map - Trie

Else - Map/Set for O(1) time & O(n) space - Sort input for O(nlogn) time and O(1) space

🚀 Getting Started

Explore the questions and solutions in C++:

🤝 Contributing

We welcome contributions! If you have more questions, improved solutions, or any suggestions, follow these steps:

  1. Fork the repository.
  2. Create a new branch for your changes.
  3. Make your contributions.
  4. Submit a pull request.

For more details, please check our Contribution Guidelines.

📝 License

This repository is licensed under the MIT License, allowing you to use, modify, and distribute the code freely.

🌈 Community

Join our community and connect with fellow learners on Discord.

Community Image

Happy coding! 🚀

About

Top interview questions on DSA , a guide for cracking on-campus and off-campus placement

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors