摘要:
题目要求 Given an array of integers where 1 ≤ a[i] ≤ n (n = size of array), some elements appear twice and others appear once. Find all the elements of [1 阅读全文
摘要:
题目要求 Given an array A of integers, return true if and only if we can partition the array into three non-empty parts with equal sums. Formally, we can 阅读全文
摘要:
题目要求 Given a group of two strings, you need to find the longest uncommon subsequence of this group of two strings. The longest uncommon subsequence is 阅读全文
摘要:
题目要求 X is a good number if after rotating each digit individually by 180 degrees, we get a valid number that is different from X. Each digit must be r 阅读全文
摘要:
题目要求 You are given a data structure of employee information, which includes the employee's unique id, his importance value and his direct subordinates 阅读全文
摘要:
题目要求 Given two arrays, write a function to compute their intersection. 题目分析及思路 给定两个数组,要求得到它们之中共同拥有的元素列表(列表中元素是唯一的)。可以将所给数组转成集合,利用集合的交集的概念,最后将结果转成列表即可。 阅读全文
摘要:
题目要求 Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. 题目分析及思路 给定一个非负整数,要求将它的各位数相加得到一个新数并对该新数重复进行这样 阅读全文
摘要:
题目要求 Find the minimum length word from a given dictionary words, which has all the letters from the string licensePlate. Such a word is said to comple 阅读全文
摘要:
题目要求 Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. 题目分析及思路 给定一 阅读全文