Skip to content

Repository files navigation

Data Structures & Algorithms in Java

This repository contains my Java implementations of Data Structures & Algorithms concepts along with handwritten notes created during my learning journey.

Repository Structure

DSA/
├── Array-Problems/
├── Arrays/
├── Bit-Manipulation/
├── Matrices/
├── Searching/
├── Sorting/
├── Strings/
├── DSA-Java-notes.pdf
├── README.md
└── .gitignore

Topics Covered

Arrays

  • Largest Number in Array
  • Reverse Array
  • Print Pairs
  • Print Subarrays

Array Problems

  • Maximum Subarray Sum (Brute Force)
  • Maximum Subarray Sum (Prefix Sum)
  • Kadane's Algorithm
  • Trapping Rainwater
  • Buy & Sell Stocks
  • Contains Duplicate

Searching

  • Linear Search
  • Binary Search
  • Search in Rotated Sorted Array

Sorting

  • Bubble Sort (Ascending & Descending)
  • Selection Sort (Ascending & Descending)
  • Insertion Sort (Ascending & Descending)
  • Counting Sort (Ascending & Descending)
  • Java Inbuilt Sorting

Matrices

  • Matrix Search
  • Search in Sorted Matrix
  • Spiral Matrix
  • Diagonal Sum
  • Matrix Transpose
  • Largest & Smallest Element in Matrix
  • Sum of 2nd Row

Strings

  • Palindrome Check
  • String Compression
  • Anagrams
  • Lexicographical Comparison
  • Substrings
  • Uppercase Conversion
  • Count Vowels
  • Shortest Path

Bit Manipulation

  • Odd or Even
  • Get i-th Bit
  • Set i-th Bit
  • Clear i-th Bit
  • Update i-th Bit
  • Clear Last i Bits
  • Clear Range of Bits
  • Count Set Bits
  • Fast Exponentiation
  • Swap Without Temporary Variable
  • Power of 2 Check
  • Add 1 Using NOT Operator

Notes

The repository also includes:

  • DSA-Java-notes.pdf
    • Handwritten notes
    • Concept explanations
    • Algorithms
    • Time & Space Complexity analysis
    • Important observations and formulas

Technologies Used

  • Java
  • VS Code
  • Git & GitHub

Purpose

This repository is maintained to:

  • Practice Data Structures & Algorithms
  • Strengthen problem-solving skills
  • Prepare for coding interviews and online assessments
  • Track learning progress

Currently learning and adding more DSA topics regularly.

About

Java-based Data Structures and Algorithms repository covering arrays, strings, searching, sorting, matrices, and bit manipulation.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages