上一页 1 ··· 23 24 25 26 27 28 29 30 31 ··· 33 下一页
摘要: Given a 32-bit signed integer, reverse digits of an integer. Example 1: Input: 123 Output: 321 Example 2: Input: -123 Output: -321 Example 3: Input: 1 阅读全文
posted @ 2019-11-17 06:24 xuan_abc 阅读(103) 评论(0) 推荐(0)
摘要: Given a string containing just the characters '(' and ')', find the length of the longest valid (well-formed) parentheses substring. Example 1: Input: 阅读全文
posted @ 2019-11-17 05:06 xuan_abc 阅读(122) 评论(0) 推荐(0)
摘要: Given a string array words, find the maximum value of length(word[i]) * length(word[j]) where the two words do not share common letters. You may assum 阅读全文
posted @ 2019-11-17 00:54 xuan_abc 阅读(178) 评论(0) 推荐(0)
摘要: Given an array containing n distinct numbers taken from 0, 1, 2, ..., n, find the one that is missing from the array. Example 1: Input: [3,0,1] Output 阅读全文
posted @ 2019-11-15 11:57 xuan_abc 阅读(82) 评论(0) 推荐(0)
摘要: Write a function that takes an unsigned integer and return the number of '1' bits it has (also known as the Hamming weight). Example 1: Input: 0000000 阅读全文
posted @ 2019-11-14 11:46 xuan_abc 阅读(118) 评论(0) 推荐(0)
摘要: Given an integer, write a function to determine if it is a power of two. Example 1: Input: 1 Output: true Explanation: 20 = 1 Example 2: Input: 16 Out 阅读全文
posted @ 2019-11-14 11:04 xuan_abc 阅读(81) 评论(0) 推荐(0)
摘要: Given two strings s and t which consist of only lowercase letters. String t is generated by random shuffling string s and then add one more letter at 阅读全文
posted @ 2019-11-13 12:32 xuan_abc 阅读(103) 评论(0) 推荐(0)
摘要: Given a non-empty array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runti 阅读全文
posted @ 2019-11-13 12:21 xuan_abc 阅读(91) 评论(0) 推荐(0)
摘要: A strobogrammatic number is a number that looks the same when rotated 180 degrees (looked at upside down). Write a function to determine if a number i 阅读全文
posted @ 2019-11-12 11:03 xuan_abc 阅读(85) 评论(0) 推荐(0)
摘要: Given a string s and a string t, check if s is subsequence of t. You may assume that there is only lower case English letters in both s and t. t is po 阅读全文
posted @ 2019-11-12 10:30 xuan_abc 阅读(138) 评论(0) 推荐(0)
上一页 1 ··· 23 24 25 26 27 28 29 30 31 ··· 33 下一页