摘要:
Single Number IIIGiven an array of numbersnums, in which exactly two elements appear only once and all the other elements appear exactly twice. Find t... 阅读全文
摘要:
Longest Substring Without Repeating Characters Longest Substring Without Repeating Characters Given a string, find the length of the longest substring 阅读全文
摘要:
Missing NumberGiven an array containingndistinct numbers taken from0, 1, 2, ..., n, find the one that is missing from the array.For example,Givennums=... 阅读全文
摘要:
Course Schedule IIThere are a total ofncourses you have to take, labeled from0ton - 1.Some courses may have prerequisites, for example to take course ... 阅读全文
摘要:
Course ScheduleThere are a total ofncourses you have to take, labeled from0ton - 1.Some courses may have prerequisites, for example to take course 0 y... 阅读全文
摘要:
Ugly Number IIWrite a program to find then-th ugly number.Ugly numbers are positive numbers whose prime factors only include2, 3, 5. For example,1, 2,... 阅读全文
摘要:
Ugly NumberWrite a program to check whether a given number is an ugly number.Ugly numbers are positive numbers whose prime factors only include2, 3, 5... 阅读全文
摘要:
Single Number IIGiven an array of integers, every element appearsthreetimes except for one. Find that single one.Note:Your algorithm should have a lin... 阅读全文
摘要:
Single NumberGiven an array of integers, every element appearstwiceexcept for one. Find that single one.Note:Your algorithm should have a linear runti... 阅读全文
摘要:
Binary Tree PathsGiven a binary tree, return all root-to-leaf paths.For example, given the following binary tree: 1 / \2 3 \ 5All root-to-lea... 阅读全文