随笔分类 - LeetCode
摘要:题目描述:Container With Most WaterGivennnon-negative integersa1,a2, ...,an, where each represents a point at coordinate (i,ai).nvertical lines are drawn s...
阅读全文
摘要:题目描述:Regular Expression MatchingImplement regular expression matching with support for'.'and'*''.' Matches any single character.'*' Matches zero or mo...
阅读全文
摘要:题目描述:Palindrome NumberDetermine whether an integer is a palindrome. Do this without extra space.Some hints:Could negative integers be palindromes? (ie...
阅读全文
摘要:题目描述:String to Integer (atoi)Implementatoito convert a string to an integer.Hint:Carefully consider all possible input cases. If you want a challenge,...
阅读全文
摘要:题目描述:Reverse IntegerReverse digits of an integer.Example1:x = 123, return 321Example2:x = -123, return -321Have you thought about this?Here are some g...
阅读全文
摘要:题目描述:ZigZag ConversionThe string"PAYPALISHIRING"is written in a zigzag pattern on a given number of rows like this: (you may want to display this patt...
阅读全文
摘要:题目描述:Longest Palindromic SubstringGiven a stringS, find the longest palindromic substring inS. You may assume that the maximum length ofSis 1000, and ...
阅读全文
摘要:题目描述:Median of Two Sorted ArraysThere are two sorted arrays A and B of size m and n respectively. Find the median of the two sorted arrays. The overal...
阅读全文
摘要:题目描述:Longest Substring Without Repeating CharactersGiven a string, find the length of the longest substring without repeating characters. For example,...
阅读全文
摘要:题目描述:Add Two NumbersYou are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nod...
阅读全文
摘要:题目描述:Two SumGiven an array of integers, find two numbers such that they add up to a specific target number.The function twoSum should return indices o...
阅读全文