上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 76 下一页
摘要: Given two strings s1 and s2, write a function to return true if s2 contains the permutation of s1. In other words, one of the first string's permutati 阅读全文
posted @ 2020-09-02 05:28 Schwifty 阅读(127) 评论(0) 推荐(0)
摘要: 把上题的2换成k即可 public int lengthOfLongestSubstringKDistinct(String s, int k) { if (s == null || s.length() == 0 || k == 0) { return 0; } char[] sArr = s.t 阅读全文
posted @ 2020-09-02 05:00 Schwifty 阅读(171) 评论(0) 推荐(0)
摘要: Given a string s , find the length of the longest substring t that contains at most 2 distinct characters. Example 1: Input: "eceba" Output: 3 Explana 阅读全文
posted @ 2020-09-02 04:59 Schwifty 阅读(124) 评论(0) 推荐(0)
摘要: Given an array of 4 digits, return the largest 24 hour time that can be made. The smallest 24 hour time is 00:00, and the largest is 23:59. Starting f 阅读全文
posted @ 2020-09-01 22:52 Schwifty 阅读(189) 评论(0) 推荐(0)
摘要: There are 3n piles of coins of varying size, you and your friends will take piles of coins as follows: In each step, you will choose any 3 piles of co 阅读全文
posted @ 2020-08-30 12:41 Schwifty 阅读(210) 评论(0) 推荐(0)
摘要: Your task is to form an integer array nums from an initial array of zeros arr that is the same size as nums. Return the minimum number of function cal 阅读全文
posted @ 2020-08-30 12:11 Schwifty 阅读(210) 评论(0) 推荐(0)
摘要: Given a directed acyclic graph, with n vertices numbered from 0 to n-1, and an array edges where edges[i] = [fromi, toi] represents a directed edge fr 阅读全文
posted @ 2020-08-30 11:07 Schwifty 阅读(285) 评论(0) 推荐(0)
摘要: Given an integer n, add a dot (".") as the thousands separator and return it in string format. Example 1: Input: n = 987 Output: "987" Example 2: Inpu 阅读全文
posted @ 2020-08-30 09:24 Schwifty 阅读(310) 评论(0) 推荐(0)
摘要: Given an array of integers A, We need to sort the array performing a series of pancake flips. In one pancake flip we do the following steps: Choose an 阅读全文
posted @ 2020-08-30 06:14 Schwifty 阅读(161) 评论(0) 推荐(0)
摘要: Given a (singly) linked list with head node root, write a function to split the linked list into k consecutive linked list "parts". The length of each 阅读全文
posted @ 2020-08-29 03:48 Schwifty 阅读(131) 评论(0) 推荐(0)
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 76 下一页