Medium ====== - :doc:`Add Two Numbers ` -- You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse... - :doc:`Binary Tree Level Order Traversal ` -- Given the root of a binary tree, return *the level order traversal of its nodes' values*. (i.e., from left to right,... - :doc:`Binary Tree Zigzag Level Order Traversal ` -- Given the root of a binary tree, return *the zigzag level order traversal of its nodes' values*. (i.e., from left to... - :doc:`Bitwise AND Of Numbers Range ` -- Given two integers left and right that represent the range [left, right], return *the bitwise AND of all numbers in... - :doc:`Construct Binary Tree From Preorder And Inorder Traversal ` -- Given two integer arrays preorder and inorder where preorder is the preorder traversal of a binary tree and inorder is... - :doc:`Container With Most Water ` -- You are given an integer array height of length n. There are n vertical lines drawn such that the two endpoints of the... - :doc:`Count And Say ` -- The count-and-say sequence is a sequence of digit strings defined by the recursive formula: - countAndSay(1) = "1" -... - :doc:`Count Primes ` -- Given an integer n, return *the number of prime numbers that are strictly less than* n. - :doc:`Delete Node In A Linked List ` -- There is a singly-linked list head and we want to delete a node node in it. You are given the node to be deleted node.... - :doc:`Divide Two Integers ` -- Given two integers dividend and divisor, divide two integers without using multiplication, division, and mod operator.... - :doc:`Find First And Last Position Of Element In Sorted Array ` -- Given an array of integers nums sorted in non-decreasing order, find the starting and ending position of a given target... - :doc:`Game Of Life ` -- According to `Wikipedia's article `__: "The Game of Life, also... - :doc:`Gas Station ` -- There are n gas stations along a circular route, where the amount of gas at the i\ :sup:`th` station is gas[i]. You... - :doc:`Generate Parentheses ` -- Given n pairs of parentheses, write a function to *generate all combinations of well-formed parentheses*. - :doc:`Group Anagrams ` -- Given an array of strings strs, group the anagrams together. You can return the answer in any order. - :doc:`H Index ` -- Given an array of integers citations where citations[i] is the number of citations a researcher received for their i\... - :doc:`Insert Delete Get Random O1 ` -- Implement the RandomizedSet class: - RandomizedSet() Initializes the RandomizedSet object. - bool insert(int val)... - :doc:`Integer To Roman ` -- Seven different symbols represent Roman numerals with the following values: ====== ===== Symbol Value ====== ===== I ... - :doc:`Jump Game ` -- You are given an integer array nums. You are initially positioned at the array's first index, and each element in the... - :doc:`LRU Cache ` -- Design a data structure that follows the constraints of a `Least Recently Used (LRU) cache... - :doc:`Length Of Longest Substring ` -- Given a string s, find the length of the longest substring without duplicate characters. - :doc:`Letter Combinations Of A Phone Number ` -- Given a string containing digits from 2-9 inclusive, return all possible letter combinations that the number could... - :doc:`Longest Palindromic Substring ` -- Given a string s, return the longest palindromic substring in s. - :doc:`Maximum Subarray ` -- Given an integer array nums, find the subarray with the largest sum, and return its sum. - :doc:`Merge Intervals ` -- Given an array of intervals where intervals[i] = [start\ :sub:`i`\ , end\ :sub:`i`\ ], merge all overlapping intervals,... - :doc:`Permutations ` -- Given an array nums of distinct integers, return all the possible permutations. You can return the answer in any order. - :doc:`Pow ` -- Implement `pow(x, n) `__, which calculates x raised to the power n... - :doc:`Product Of Array Except Self ` -- Given an integer array nums, return an array answer *such that answer[i] is equal to the product of all the elements... - :doc:`Remove Duplicates From Sorted Array II ` -- Given an integer array nums sorted in non-decreasing order, remove some duplicates `in-place... - :doc:`Remove Nth Node From End Of List ` -- Given the head of a linked list, remove the n\ :sup:`th` node from the end of the list and return its head. - :doc:`Reverse Integer ` -- Given a signed 32-bit integer x, return x *with its digits reversed*. If reversing x causes the value to go outside the... - :doc:`Reverse Words In A String ` -- Given an input string s, reverse the order of the words. A word is defined as a sequence of non-space characters. The... - :doc:`Rotate Image ` -- You are given an n x n 2D matrix representing an image, rotate the image by 90 degrees (clockwise). You have to rotate... - :doc:`Search In Rotated Array ` -- There is an integer array nums sorted in ascending order (with distinct values). Prior to being passed to your... - :doc:`Set Matrix Zeroes ` -- Given an m x n integer matrix matrix, if an element is 0, set its entire row and column to 0's. You must do it `in... - :doc:`Single Number II ` -- Given an integer array nums where every element appears **three times except for one, which appears exactly once*. Find... - :doc:`Sort List ` -- Given the head of a linked list, return *the list after sorting it in* ascending order. - :doc:`String To Integer ` -- Implement the myAtoi(string s) function, which converts a string to a 32-bit signed integer. The algorithm for... - :doc:`Subsets ` -- Given an integer array nums of unique elements, return *all possible subsets (the power set)*. The solution set must... - :doc:`Three Sum ` -- Given an integer array nums, return all the triplets [nums[i], nums[j], nums[k]] such that i != j, i != k, and j != k,... - :doc:`Tries ` - :doc:`Two Sum II ` -- Given a 1-indexed array of integers numbers that is already sorted in non-decreasing order, find two numbers such that... - :doc:`Valid Sudoku ` -- Determine if a 9 x 9 Sudoku board is valid. Only the filled cells need to be validated according to the following... - :doc:`Zig Zag Conversion ` -- The string "PAYPALISHIRING" is written in a zigzag pattern on a given number of rows like this: (you may want to...