上一页 1 ··· 6 7 8 9 10 11 12 13 14 ··· 23 下一页
摘要: Problem : Given an integer n, return 1 n in lexicographical order. For example, given 13, return: [1,10,11,12,13,2,3,4,5,6,7,8,9]. Please optimize you 阅读全文
posted @ 2020-04-09 10:48 littledy 阅读(92) 评论(0) 推荐(0)
摘要: Problem : Given a n x n matrix where each of the rows and columns are sorted in ascending order, find the kth smallest element in the matrix. Note tha 阅读全文
posted @ 2020-04-09 10:27 littledy 阅读(96) 评论(0) 推荐(0)
摘要: Problem : Your task is to calculate ab mod 1337 where a is a positive integer and b is an extremely large positive integer given in the form of an arr 阅读全文
posted @ 2020-04-08 01:29 littledy 阅读(118) 评论(0) 推荐(0)
摘要: Problem : Given a non negative integer n, count all numbers with unique digits, x, where 0 ≤ x < 10n. Example: 思路 : Solution (C++) : 性能 : Runtime: 0 m 阅读全文
posted @ 2020-04-07 23:57 littledy 阅读(103) 评论(0) 推荐(0)
摘要: Problem : Write a function that takes a string as input and reverse only the vowels of a string. Example 1: Example 2: Note: The vowels does not inclu 阅读全文
posted @ 2020-04-07 23:14 littledy 阅读(88) 评论(0) 推荐(0)
摘要: Problem : Given a positive integer n, break it into the sum of at least two positive integers and maximize the product of those integers. Return the m 阅读全文
posted @ 2020-04-07 21:45 littledy 阅读(95) 评论(0) 推荐(0)
摘要: Problem : Given a non empty array of integers, return the k most frequent elements. Example 1: Example 2: Note: You may assume k is always valid, 1 ≤ 阅读全文
posted @ 2020-04-07 16:58 littledy 阅读(95) 评论(0) 推荐(0)
摘要: Problem : Write a function that reverses a string. The input string is given as an array of characters char[]. Do not allocate extra space for another 阅读全文
posted @ 2020-04-07 13:49 littledy 阅读(76) 评论(0) 推荐(0)
摘要: Problem : Given a non negative integer number num. For every numbers i in the range 0 ≤ i ≤ num calculate the number of 1's in their binary representa 阅读全文
posted @ 2020-04-07 13:11 littledy 阅读(97) 评论(0) 推荐(0)
摘要: Problem : Given an integer, write a function to determine if it is a power of three. Example 1: Example 2: Example 3: Example 4: Follow up: Could you 阅读全文
posted @ 2020-04-07 12:43 littledy 阅读(103) 评论(0) 推荐(0)
上一页 1 ··· 6 7 8 9 10 11 12 13 14 ··· 23 下一页