Welcome to Algo Hub

Here, you’ll find detailed walkthrough of solutions for a variety of problems sourced from top coding platforms.

Whether you’re preparing for technical interviews, sharpening your problem-solving skills, or simply delving into the world of algorithms, I try to provide clear explanations and step-by-step guides, with insights and strategies to help you succeed.

Latest Solutions and walkthroughs

Longest Substring Without Repeating Characters

MediumLeetCodeHash TableStringSliding Window

This challenge here is to find the longest substring without repeating characters. You can find the original problem described on LeetCode. Problem Statement Given a string s, find the length of the longest substring without repeating characters. The problem definition on LeetCode also defines what is a substring: “A substring is a contiguous non-empty sequence of characters within a string”. Example 1 Input: s = "abcabcbb" Output: 3 Explanation: The answer is “abc”, with the length of 3.

Read more →

July 17, 2024

Add Two Numbers

MediumLeetCodeLinked ListMathRecursion

This problem involves adding two numbers represented by linked lists. You can find the original problem described on LeetCode. Problem Statement You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order, and each of their nodes contains a single digit. Add the two numbers and return the sum as a linked list. You may assume the two numbers do not contain any leading zero, except the number 0 itself.

Read more →

July 4, 2024

Two Sum

EasyLeetCodeArrayHash Table

The task is to find two numbers in an array that add up to a specific target. You can find the original problem described on LeetCode. Problem Statement Given an array of integers nums and an integer target, return indices of the two numbers such that they add up to target. You may assume that each input would have exactly one solution, and you may not use the same element twice.

Read more →

July 3, 2024

Check all problem solutions and run the test cases easily with LeetSwift! 🚀