随笔分类 - LeetCode
解题思路记录
摘要:题目描述 LeetCode原题链接:2281. Sum of Total Strength of Wizards As the ruler of a kingdom, you have an army of wizards at your command. You are given a 0-ind
阅读全文
摘要:题目描述 LeetCode原题链接:828. Count Unique Characters of All Substrings of a Given String Let's define a function countUniqueChars(s) that returns the number
阅读全文
摘要:题目描述 LeetCode原题链接:818. Race Car Your car starts at position 0 and speed +1 on an infinite number line. Your car can go into negative positions. Your c
阅读全文
摘要:题目描述 LeetCode原题链接:373. Find K Pairs with Smallest Sums You are given two integer arrays nums1 and nums2 sorted in ascending order and an integer k. De
阅读全文
摘要:题目描述 LeetCode原题链接:1621. Number of Sets of K Non-Overlapping Line Segments Given n points on a 1-D plane, where the ith point (from 0 to n-1) is at x =
阅读全文
摘要:题目描述 LeetCode原题链接:395. Longest Substring with At Least K Repeating Characters Given a string s and an integer k, return the length of the longest subs
阅读全文
摘要:题目描述 LeetCode原题链接:410. Split Array Largest Sum Given an array nums which consists of non-negative integers and an integer m, you can split the array i
阅读全文
摘要:题目描述 LeetCode原题链接:1262. Greatest Sum Divisible by Three Given an array nums of integers, we need to find the maximum possible sum of elements of the a
阅读全文
摘要:题目描述 LeetCode原题链接:1320. Minimum Distance to Type a Word Using Two Fingers You have a keyboard layout as shown above in the X-Y plane, where each Engli
阅读全文
摘要:题目描述 LeetCode原题链接:642. Design Search Autocomplete System Design a search autocomplete system for a search engine. Users may input a sentence (at least
阅读全文
摘要:LeetCode解题思路汇总(loading......) 做个记录啦📝 4 Hard Median of Two Sorted Arrays 10 Hard Regular Expression Matching 221 Medium Maximal Square 222 Medium Coun
阅读全文
摘要:题目描述 LeetCode原题链接:221. Maximal Square Given an m x n binary matrix filled with 0's and 1's, find the largest square containing only 1's and return its
阅读全文
摘要:题目描述 LeetCode原题链接:222. Count Complete Tree Nodes Given the root of a complete binary tree, return the number of the nodes in the tree. According to Wi
阅读全文
摘要:题目描述 LeetCode原题链接:10. Regular Expression Matching Given an input string s and a pattern p, implement regular expression matching with support for '.'
阅读全文
摘要:题目描述 LeetCode原题链接:4. Median of Two Sorted Arrays Given two sorted arrays nums1 and nums2 of size m and n respectively, return the median of the two so
阅读全文
摘要:题目描述 LeetCode原题链接:287. Find the Duplicate Number Given an array of integers nums containing n + 1 integers where each integer is in the range [1, n] i
阅读全文

浙公网安备 33010602011771号