LeetCode
karlzpsong
ByteDance Recommend | SYSU本/硕
展开
-
LeetCode 30天挑战 Day-30
LeetCode 30 days Challenge - Day 30 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Check If a String Is a Valid Sequence from Root to Leaves Path in a Binary Tree Given a binary tree wh...原创 2020-04-30 16:28:07 · 464 阅读 · 0 评论 -
LeetCode 30天挑战 Day-29
LeetCode 30 days Challenge - Day 29 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Binary Tree Maximum Path Sum Given a non-empty binary tree, find the maximum path sum. For this proble...原创 2020-04-29 19:02:30 · 137 阅读 · 0 评论 -
LeetCode 30天挑战 Day-28
LeetCode 30 days Challenge - Day 28 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 First Unique Number You have a queue of integers, you need to retrieve the first unique integer in the...原创 2020-04-28 22:22:40 · 139 阅读 · 0 评论 -
LeetCode 30天挑战 Day-27
LeetCode 30 days Challenge - Day 27 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Maximal Square Given a 2D binary matrix filled with 0’s and 1’s, find the largest square containing on...原创 2020-04-27 17:03:12 · 280 阅读 · 0 评论 -
LeetCode 30天挑战 Day-26
LeetCode 30 days Challenge - Day 26 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Longest Common Subsequence Given two strings text1 and text2, return the length of their longest commo...原创 2020-04-27 15:05:19 · 153 阅读 · 0 评论 -
LeetCode 30天挑战 Day-25
LeetCode 30 days Challenge - Day 25 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Jump Game Given an array of non-negative integers, you are initially positioned at the first index of ...原创 2020-04-25 18:40:31 · 187 阅读 · 0 评论 -
LeetCode 30天挑战 Day-24
LeetCode 30 days Challenge - Day 24 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 LRU Cache Design and implement a data structure for Least Recently Used (LRU) cache. It should support...原创 2020-04-25 11:49:01 · 127 阅读 · 0 评论 -
LeetCode 30天挑战 Day-23
LeetCode 30 days Challenge - Day 23 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Bitwise AND of Numbers Range Given a range [m, n] where 0 <= m <= n <= 2147483647, return the...原创 2020-04-23 17:12:10 · 169 阅读 · 0 评论 -
LeetCode 30天挑战 Day-22
LeetCode 30 days Challenge - Day 22 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Subarray Sum Equals K Given an array of integers and an integer k, you need to find the total number o...原创 2020-04-22 17:13:52 · 117 阅读 · 0 评论 -
LeetCode 30天挑战 Day-21
LeetCode 30 days Challenge - Day 21 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Leftmost Column with at Least a One (This problem is an interactive problem.) A binary matrix means th...原创 2020-04-21 17:22:50 · 342 阅读 · 0 评论 -
LeetCode 30天挑战 Day-20
LeetCode 30 days Challenge - Day 20 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Construct Binary Search Tree from Preorder Traversal Return the root node of a binary search tree that...原创 2020-04-20 16:45:04 · 170 阅读 · 0 评论 -
LeetCode 30天挑战 Day-19
LeetCode 30 days Challenge - Day 19 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Search in Rotated Sorted Array Suppose an array sorted in ascending order is rotated at some pivot unk...原创 2020-04-20 11:38:05 · 137 阅读 · 0 评论 -
LeetCode 30天挑战 Day-18
LeetCode 30 days Challenge - Day 18 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Minimum Path Sum Given a m x n grid filled with non-negative numbers, find a path from top left to bot...原创 2020-04-20 11:21:46 · 177 阅读 · 0 评论 -
LeetCode 30天挑战 Day-17
LeetCode 30 days Challenge - Day 17 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Number of Islands Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An...原创 2020-04-17 16:27:45 · 114 阅读 · 0 评论 -
LeetCode 30天挑战 Day-16
LeetCode 30 days Challenge - Day 16 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Valid Parenthesis String Given a string containing only three types of characters: ‘(’, ‘)’ and ‘*’, w...原创 2020-04-16 17:07:09 · 103 阅读 · 0 评论 -
LeetCode 30天挑战 Day-15
LeetCode 30 days Challenge - Day 15 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Product of Array Except Self Given an array nums of n integers where n > 1, return an array output...原创 2020-04-15 16:03:16 · 103 阅读 · 0 评论 -
LeetCode 30天挑战 Day-14
LeetCode 30 days Challenge - Day 14 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Perform String Shifts You are given a string s containing lowercase English letters, and a matrix shif...原创 2020-04-14 23:07:39 · 257 阅读 · 0 评论 -
LeetCode 30天挑战 Day-13
LeetCode 30 days Challenge - Day 13 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Contiguous Array Given a binary array, find the maximum length of a contiguous subarray with equal num...原创 2020-04-13 16:06:33 · 109 阅读 · 0 评论 -
LeetCode 30天挑战 Day-12
LeetCode 30 days Challenge - Day 12 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Last Stone Weight We have a collection of stones, each stone has a positive integer weight. Each turn,...原创 2020-04-12 16:34:31 · 97 阅读 · 0 评论 -
LeetCode 30天挑战 Day-11
LeetCode 30 days Challenge - Day 11 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Diameter of Binary Tree Given a binary tree, you need to compute the length of the diameter of the tre...原创 2020-04-11 16:48:38 · 119 阅读 · 0 评论 -
LeetCode 30天挑战 Day-10
LeetCode 30 days Challenge - Day 10 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Min Stack Design a stack that supports push, pop, top, and retrieving the minimum element in constant ...原创 2020-04-10 16:54:48 · 145 阅读 · 0 评论 -
LeetCode 30天挑战 Day-9
LeetCode 30 days Challenge - Day 9 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Backspace String Compare Given two strings S and T, return if they are equal when both are typed into e...原创 2020-04-10 12:35:42 · 124 阅读 · 0 评论 -
LeetCode 30天挑战 Day-8
LeetCode 30 days Challenge - Day 8 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Middle of the Linked List Given a non-empty, singly linked list with head node head, return a middle no...原创 2020-04-08 21:35:32 · 94 阅读 · 0 评论 -
LeetCode 30天挑战 Day-7
LeetCode 30 days Challenge - Day 7 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Counting Elements Given an integer array arr, count element x such that x + 1 is also in arr. If there’...原创 2020-04-07 17:28:38 · 175 阅读 · 0 评论 -
LeetCode 30天挑战 Day-6
LeetCode 30 days Challenge - Day 6 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Group Anagrams Given an array of strings, group anagrams together. Example: Input: ["eat", "tea", "tan"...原创 2020-04-06 17:28:21 · 139 阅读 · 0 评论 -
LeetCode 30天挑战 Day-5
LeetCode 30 days Challenge - Day 5 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Best Time to Buy and Sell Stock II Say you have an array for which the ith element is the price of a gi...原创 2020-04-06 16:49:13 · 161 阅读 · 0 评论 -
LeetCode 30天挑战 Day-4
LeetCode 30 days Challenge - Day 4 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Move Zeroes Given an array nums, write a function to move all 0's to the end of it while maintaining th...原创 2020-04-06 16:28:02 · 155 阅读 · 0 评论 -
LeetCode 30天挑战 Day-3
LeetCode 30 days Challenge - Day 3 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Maximum Subarray Solution Given an integer array nums, find the contiguous subarray (containing at leas...原创 2020-04-04 23:02:27 · 168 阅读 · 0 评论 -
LeetCode 30天挑战 Day-2
LeetCode 30 days Challenge - Day 2 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Happy Number Write an algorithm to determine if a number is “happy”. A happy number is a number defined...原创 2020-04-04 22:23:49 · 118 阅读 · 0 评论 -
LeetCode 30天挑战 Day-1
LeetCode 30 days Challenge - Day 1 本系列将对LeetCode新推出的30天算法挑战进行总结记录,旨在记录学习成果、方便未来查阅,同时望为广大网友提供帮助。 Single Number Given a non-empty array of integers, every element appears twice except for one. Find tha...原创 2020-04-04 22:22:42 · 216 阅读 · 0 评论