This repository is a hands-on guide for learning data structures and algorithms (DSA). It includes TypeScript code examples, test cases, and helpful utilities to make writing and testing solutions easier and more effective.
This project uses Jest for testing each solution to ensure everything works as expected.
To run all tests, simply use: npm run test.
-
Algorithms
- Anagram
- Array Operations
- Maximum Average Subarray I
- Max Consecutive Ones III
- Merge Sorted Array
- Minimum Value to Get Positive Step by Step Sum
- Minimum SizeSubarray Sum
- Minimum Window Substring
- Remove Duplicate Objects
- Remove Duplicates from Sorted Array
- Running Sum of 1d Array
- Squares of Sorted Array
- K Radius Subarray Averages
- Capitalize
- Fibonacci
- FizzBuzz
- Longest Substring
- Palindrome
- Pangram
- Reverse String
- Sorting
- String Operations
- Missing Number
- Two Sum
-
Data Structures
-
Exercises
- Closures
- Promise Time Limit
This project will continue to grow and evolve. It is organized by algorithms, data structures, and exercises. Each implementation includes unit tests.
root/
│
├── src/
│ ├── algorithms/
│ │ ├── sorting/
│ │ │ ├── bubbleSort.ts
│ │ │ ├── bubbleSort.test.js
│ │ │ └── ...
│ │ └── .../
│ ├── dataStructures/
│ │ ├── queue/
│ │ │ ├── queue.ts
│ │ │ ├── queue.test.js
│ │ └── ...
│ ├── exercises/
│ │ ├── debouce
│ │ │ ├── debounce.ts
│ │ │ ├── debounce.test.js
│ │ └── ...
├── package.json
└── jest.config.js