Welcome to my collection of LeetCode problem solutions written in C++, organized simply by question number for quick access and clarity.
This repository is my personal archive to track progress, revise daily, and help others who are practicing for coding interviews and competitive programming.
- 🟦 Solutions are named using the LeetCode problem number, like
1.cpp,42.cpp, etc. - 🔢 Covers a wide range of topics including arrays, linked lists, trees, DP, backtracking, and more.
- ⏱ Most questions are solved using optimal or near-optimal time/space complexity.
- 📘 Written using clean, readable, and beginner-friendly C++ code.
Here’s how solutions are named:
- LC_1.cpp //Two Sum
- LC_2.cpp //Add Two Numbers
You can search the LeetCode website using the question number to match it with the solution.
- 📚 Revise core DSA concepts and common patterns (e.g., sliding window, two pointers, recursion).
- 🧠 Great reference during interviews and contests.
- 🤝 Helpful for students, job seekers, and those practicing consistently on LeetCode.
- ✨ All code is hand-written, well-tested, and explained with comments wherever needed.
- Start with easy/medium questions by topic (e.g., Arrays, Strings, Linked Lists).
- Focus on patterns like Binary Search, Heap, Backtracking, DP, etc.
- Try solving problems yourself first, then refer to solutions here as needed.
-
Clone the repo:
# Clone the main repository from the parent directory git clone https://github.com/your-username/your-new-repo-name.git -
Open any
.cppfile using your preferred C++ IDE (VS Code, CodeBlocks, etc.) -
Run and test locally, or copy into an online IDE like LeetCode Playground or OnlineGDB.
- 🔗 LinkedIn – Ali Us Samad
- 📧 Email: aliussamad@gmail.com
Give the repository a 🌟 on GitHub and help others find it!
Happy Coding!
— Ali Us Samad