Helping engineers with technical interviews

Tag: Two-Pointer

Leetcode 463 Island Perimeter

Leetcode 724 Find Pivot Index

Given an array of integers nums, calculate the pivot index of this array. The pivot index is the index where the sum of all the numbers strictly to the left of the index is equal to the sum of all the numbers strictly to the index’s right. If the index is on the left edge […]

Read More
Leetcode 463 Island Perimeter

Valid Palindrome

A palindrome is a word, phrase, or sequence of characters that reads the same backward as forward. For example, “racecar” is a palindrome because it is spelled the same way forwards and backwards. A valid palindrome is a palindrome that also meets certain conditions. One common condition is that spaces and punctuation marks are ignored […]

Read More
Leetcode 463 Island Perimeter

Three Sum Coding Problem Solution

The Three Sum problem is a well-known problem in computer science that involves finding all unique triplets in an array of integers that add up to a target sum. For example, given the array [1, 2, 3, 4, 5, 6, 7] and a target sum of 10, the solution would be [[1, 2, 7], [1, […]

Read More
Leetcode 463 Island Perimeter

Container With Most Water

The Container With Most Water is a classic problem in algorithmic and computational thinking, that is often used to test the efficiency and problem-solving skills of developers. The problem statement is as follows: You are given a list of n non-negative integers, where each integer represents a vertical line at position i with a height […]

Read More

Powered by WordPress & Theme by Anders Norén