LeetCode342 leetcode 234. Palindrome Linked List https://leetcode.com/problems/palindrome-linked-list/ Palindrome Linked List - LeetCode Palindrome Linked List - Given the head of a singly linked list, return true if it is a palindrome or false otherwise. Example 1: [https://assets.leetcode.com/uploads/2021/03/03/pal1linked-list.jpg] Input: head = [1,2,2,1] Output: true Example 2: [https leetcode.com 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1.. 2023. 2. 11. leetcode 121. Best Time to Buy and Sell Stock https://leetcode.com/problems/best-time-to-buy-and-sell-stock/ Best Time to Buy and Sell Stock - LeetCode Best Time to Buy and Sell Stock - You are given an array prices where prices[i] is the price of a given stock on the ith day. You want to maximize your profit by choosing a single day to buy one stock and choosing a different day in the future to sell that leetcode.com 1 2 3 4 5 6 7 8 9 10 c.. 2023. 2. 11. leetcode 2149. Rearrange Array Elements by Sign https://leetcode.com/problems/rearrange-array-elements-by-sign/description/ Rearrange Array Elements by Sign - LeetCode Can you solve this real interview question? Rearrange Array Elements by Sign - You are given a 0-indexed integer array nums of even length consisting of an equal number of positive and negative integers. You should rearrange the elements of nums such that leetcode.com 1 2 3 4 5.. 2023. 2. 10. leetcode 238. Product of Array Except Self https://leetcode.com/problems/product-of-array-except-self/description/ Product of Array Except Self - LeetCode 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 of nums except nums[i]. The product of any prefix or suffix of nums is guaranteed to fit in a 32-bit integer. leetcode.com 1 2 3 4 5 6 7 8 .. 2023. 2. 10. leetcode 15. 3Sum https://leetcode.com/problems/3sum/description/ 3Sum - LeetCode 3Sum - Given an integer array nums, return all the triplets [nums[i], nums[j], nums[k]] such that i != j, i != k, and j != k, and nums[i] + nums[j] + nums[k] == 0. Notice that the solution set must not contain duplicate triplets. Example 1: Input: nums leetcode.com 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26.. 2023. 2. 9. leetcode 42. Trapping Rain Water https://leetcode.com/problems/trapping-rain-water/description/ Trapping Rain Water - LeetCode Trapping Rain Water - Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it can trap after raining. Example 1: [https://assets.leetcode.com/uploads/2018/10/22/rainwatertrap.png] Input: he leetcode.com 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1.. 2023. 2. 9. leetcode 5. Longest Palindromic Substring https://leetcode.com/problems/longest-palindromic-substring/description/ Longest Palindromic Substring - LeetCode Longest Palindromic Substring - Given a string s, return the longest palindromic substring in s. Example 1: Input: s = "babad" Output: "bab" Explanation: "aba" is also a valid answer. Example 2: Input: s = "cbbd" Output: "bb" Constraints: * 1 str: def expand(left: int, right: int) ->.. 2023. 2. 8. leetcode 49. Group Anagrams https://leetcode.com/problems/group-anagrams/description/ Group Anagrams - LeetCode Can you solve this real interview question? Group Anagrams - Given an array of strings strs, group the anagrams together. You can return the answer in any order. An Anagram is a word or phrase formed by rearranging the letters of a different word or phrase leetcode.com 1 2 3 4 5 6 7 8 9 10 import collections clas.. 2023. 2. 7. leetcode 819. Most Common Word https://leetcode.com/problems/most-common-word/description/ Most Common Word - LeetCode Most Common Word - Given a string paragraph and a string array of the banned words banned, return the most frequent word that is not banned. It is guaranteed there is at least one word that is not banned, and that the answer is unique. The words in paragra leetcode.com 1 2 3 4 5 6 7 8 9 10 11 import re import.. 2023. 2. 7. leetcode 937. Reorder Data in Log Files https://leetcode.com/problems/reorder-data-in-log-files/description/ Reorder Data in Log Files - LeetCode Reorder Data in Log Files - You are given an array of logs. Each log is a space-delimited string of words, where the first word is the identifier. There are two types of logs: * Letter-logs: All words (except the identifier) consist of lowercase English le leetcode.com 1 2 3 4 5 6 7 8 9 10 1.. 2023. 2. 7. leetcode 1967. Number of Strings That Appear as Substrings in Word https://leetcode.com/problems/number-of-strings-that-appear-as-substrings-in-word/description/ Number of Strings That Appear as Substrings in Word - LeetCode Number of Strings That Appear as Substrings in Word - Given an array of strings patterns and a string word, return the number of strings in patterns that exist as a substring in word. A substring is a contiguous sequence of characters withi.. 2023. 2. 3. leetcode 1137. N-th Tribonacci Number https://leetcode.com/problems/n-th-tribonacci-number/description/ N-th Tribonacci Number - LeetCode N-th Tribonacci Number - The Tribonacci sequence Tn is defined as follows: T0 = 0, T1 = 1, T2 = 1, and Tn+3 = Tn + Tn+1 + Tn+2 for n >= 0. Given n, return the value of Tn. Example 1: Input: n = 4 Output: 4 Explanation: T_3 = 0 + 1 + 1 = 2 T_4 = 1 + 1 leetcode.com 1 2 3 4 5 6 7 8 9 10 11 class Solu.. 2023. 1. 30. 이전 1 ··· 9 10 11 12 13 14 15 ··· 29 다음