LeetCode
LeetCode copied to clipboard
LeetCode Solutions
### Difficulty Hard ### Problem Description Given two arrays `nums1` and `nums2`. Return the maximum dot product between **non-empty** subsequences of `nums1` and `nums2` with the same length. A subsequence...
### Difficulty Medium ### Problem Description Given an integer array arr of distinct integers and an integer k. A game will be played between the first two elements of the...
### Difficulty Medium ### Problem Description We have a wooden plank of the length n units. Some ants are walking on the plank, each ant moves with a speed of...
### Difficulty Medium ### Problem Description You are given an integer array target and an integer n. You have an empty stack with the two following operations: "Push": pushes an...
### Difficulty Medium ### Problem Description Given the root of a binary tree, return the number of nodes where the value of the node is equal to the average of...
### Difficulty Medium ### Problem Description Given an array of strings `strs`, group **the anagrams** together. You can return the answer in **any order**. An **Anagram** is a word or...
### Difficulty Easy ### Problem Description Given a string s consisting of words and spaces, return the length of the last word in the string. A word is a maximal...
### Difficulty Hard ### Problem Description There are buckets buckets of liquid, where exactly one of the buckets is poisonous. To figure out which one is poisonous, you feed some...
### Difficulty Medium ### Problem Description Given an array of integers citations where citations[i] is the number of citations a researcher received for their ith paper, return the researcher's h-index....
### Difficulty Hard ### Problem Description You are given an array of integers nums (0-indexed) and an integer k. The score of a subarray (i, j) is defined as min(nums[i],...