Welcome to DSA 150 Fundamentals! This repository is designed to help beginners master the essential concepts, techniques, and problem-solving skills required before diving into Data Structures and Algorithms (DSA). By completing these 150 foundational problems, you’ll build a strong base in fundamental concepts, boosting your confidence and efficiency in tackling DSA challenges.
DSA 150 Fundamentals is a curated list of problems to solve before tackling DSA. Each problem is chosen to build up your foundational knowledge step-by-step, preparing you for advanced DSA topics with ease.
- 150 Essential Questions: A structured set of questions covering basic programming and problem-solving techniques.
- Skill-Building: Each question is designed to enhance your understanding of fundamental concepts, logic, and efficient coding practices.
DSA-150-Fundamentals/
├── README.md # Project documentation
├── Easy/
│ ├── Problem_1 # Individual problem files
│ ├── Problem_2
│ ├── ...
├── Medium/
│ ├── Problem_1
│ ├── Problem_2
│ ├── ...
└── Hard/
├── Problem_1
├── Problem_2
├── ...
- Determining Even/Odd Numbers.
- Checking for Prime Numbers.
- Validating Leap Years.
- Calculating Armstrong Numbers.
- Generating the Fibonacci Series.
- Identifying Palindromes.
- Crafting Star Patterns.
- Finding the Factorial of a Number.
- Summing Digits of a Number.
- Finding the Greatest Common Divisor (GCD).
- Finding the Least Common Multiple (LCM).
- Counting Vowels and Consonants in a String.
- Reversing a String.
- Finding the Largest and Smallest Numbers in an Array.
- Sorting an Array.
- Finding the Sum of Elements in an Array.
- Checking for Armstrong Numbers in a Range.
- Generating Multiplication Tables.
- Finding Prime Numbers in a Range.
- Checking for Perfect Numbers.
- Calculating the Sum of Even Numbers in a Range.
- Calculating the Sum of Odd Numbers in a Range.
- Finding the Fibonacci Number at a Specific Position.
- Printing Prime Numbers Less Than a Given Number.
- Finding the Number of Digits in a Number.
- Checking if a Number is a Narcissistic Number.
- Generating a Pattern of Numbers.
- Finding the Sum of the Digits of the Factorial of a Number.
- Finding the Largest Palindrome in a String.
- Finding Missing Numbers in a Sequence.
- Calculating the Power of a Number.
- Checking for an Anagram.
- Finding the N-th Triangular Number.
- Checking for Perfect Squares.
- Finding the Sum of Squares of Digits.
- Finding the Count of Specific Digits in a Number.
- Finding All Divisors of a Number.
- Finding the Average of Numbers in an Array.
- Finding the Sum of Digits of a Number Until Zero.
- Generating a Multiplication Table for a Range.
- Generating a Matrix with Multiplication Table.
- Finding the Sum of the First N Odd Numbers.
- Finding the Sum of Numbers in a String.
- Checking for Perfect Squares in a Range.
- Finding the Sum of Diagonal Elements in a Matrix.
- Finding the Second Smallest Number in an Array.
- Finding the Sum of Digits of the Product of Two Numbers.
- Generating a Matrix with Alternating 0s and 1s.
- Finding the Count of a Specific Word in a String.
- Generating a Right-Angle Triangle Pattern of Numbers.
- Finding the Number of Words in a String.
- Finding the Sum of the First N Even Numbers.
- Finding the Count of Digits Greater Than a Specific Value.
- Finding the Largest Element in Each Row of a Matrix.
- Finding the Frequency of Each Character in a String.
- Generating a Matrix with Random Numbers.
- Finding the Length of the Longest Word in a String.
- Finding the Difference Between the Sum of Even and Odd Numbers in an Array.
- Generating a Triangle Pattern of Stars with a Given Height.
- Print a Square of Stars.
- Print a Diamond Pattern.
- Print a Hollow Square of Stars.
- Print an Inverted Triangle Pattern.
- Print a Diamond Pattern with Numbers.
- Print a Pyramid Pattern with Numbers.
- Generating a Pascal’s Triangle.
- Finding the Median of an Array.
- Finding the Sum of Prime Numbers in a Range.
- Generating a Square Matrix of a Given Size.
- Generating a Fibonacci Sequence Using Recursion.
- Finding the Mode of Numbers in an Array.
- Determining the Length of a String Without Using Built-In Functions.
- Finding the Second Largest Number in an Array.
- Finding the Longest Substring Without Repeating Characters.
- Calculating the Sum of a Series (1 + 1/2 + 1/3 + ... + 1/n).
- Finding All Pairs of Elements in an Array that Add Up to a Given Sum.
- Counting the Number of Palindromic Substrings in a String.
- Finding the GCD of Multiple Numbers.
- Finding the Number of Perfect Numbers Up to a Given Limit.
- Finding the Largest Prime Factor of a Number.
- Generating a Matrix of Fibonacci Numbers.
- Finding the Sum of the First N Prime Numbers.
- Checking for a Balanced Bracket Sequence.
- Finding the Longest Consecutive Sequence in an Array.
- Generating a Matrix with a Spiral Pattern.
- Finding All Subsets of a Set.
- Checking for Palindromic Numbers in a Range.
- Finding the Largest Sum of a Subarray.
- Finding All Divisors of the Product of Two Numbers.
- Finding the Longest Sequence of Consecutive 1s in a Binary Array.
- Calculating the Sum of the First N Fibonacci Numbers.
- Checking for a Repeated Substring in a String.
- Finding the Median of a List of Numbers.
- Generating a Matrix with a Diagonal Pattern.
- Generating a Pattern of Prime Numbers.
- Finding the Common Elements in Two Arrays.
- Finding the Sum of the Squares of All Even Numbers Up to N.
- Checking for Anagram Pairs in a List of Strings.
- Finding All Triplets in an Array That Sum to Zero.
- Print a Pattern of Alternating 0s and 1s.
- Print a Pattern of Consecutive Numbers.
- Print a Star Pattern with Increasing Width.
- Print a Right-Angle Triangle Pattern with Characters.
- Print a Checkerboard Pattern.
- Print a Border Pattern with Numbers.
- Print an Inverted Pyramid Pattern with Characters.
- Print a Cross Pattern with Stars.
- Finding the Sum of Prime Factors of a Number.
- Print a Pascal’s Triangle.
- Print a Matrix with Zigzag Pattern.
- Print a Pattern of Alternating Characters in Rows.
- Print a Number Pyramid Pattern with Characters.
- Print a Pattern with Diagonal Lines.
- Print a Cross Pattern of Stars with Diagonals.
- Print a Pattern with Increasing Characters in Columns.
- Print a Matrix with Zigzag Pattern of Stars.
- Checking if a Number is a Lychrel Number.
- Checking if a Number is a Harshad (Niven) Number.
- Converting a Decimal Number to Binary.
- Converting a Binary Number to Decimal.
- Finding the Nth Term in an Arithmetic Progression (AP).
- Finding the Nth Term in a Geometric Progression (GP).
- Finding the Nth Catalan Number.
- Print the First N Catalan Numbers.
- Find the Sum of First N Terms in an Arithmetic Series.
- Finding the Sum of First N Terms in a Geometric Series.
- Clone the Repository:
git clone https://github.com/Varunyadavgithub/DSA-150-Fundamentals.git
- Navigate to the Project Folder:
cd DSA-150-Fundamentals
- Practice Regularly: Aim to solve a few problems daily to build a consistent habit.
- Use Multiple Languages: Challenge yourself to solve problems in different languages (e.g., Python, JavaScript, C++).
- Refer to Solutions: If you're stuck, you can refer to solutions, but try to solve it on your own first!
- Track Your Progress: Check off problems as you complete them. You may create a
progress.txt
file to track your journey.
- Break Down Problems: Start by understanding the problem requirements and break it down into smaller steps.
- Write Clean Code: Focus on writing clean and efficient code with meaningful variable names and comments.
- Optimize Gradually: Aim for a working solution first, then gradually improve its efficiency.
- Ask for Help: Feel free to open an issue in this repository if you have questions or need clarification on a problem.
We welcome contributions from the community to improve this resource. You can contribute by:
- Adding new problems or solutions
- Improving the explanations in existing problems
- Creating additional study guides or reference material
This project is licensed under the MIT License. See the LICENSE file for details.
If you have questions or suggestions, feel free to reach out or open an issue in the repository.
Happy coding and best of luck on your journey through DSA 150 Fundamentals!