01 2019 档案

摘要:We are given a personal information string S, which may represent either an email address or a phone number. We would like to mask this personal infor 阅读全文
posted @ 2019-01-30 23:48 Grandyang 阅读(1677) 评论(0) 推荐(0) 编辑
摘要:In a string S of lowercase letters, these letters form consecutive groups of the same character. For example, a string like S = "abbxxxxzyy" has the g 阅读全文
posted @ 2019-01-28 22:21 Grandyang 阅读(1788) 评论(0) 推荐(0) 编辑
摘要:Given a set of N people (numbered 1, 2, ..., N), we would like to split everyone into two groups of any size. Each person may dislike some other peopl 阅读全文
posted @ 2019-01-24 22:08 Grandyang 阅读(4602) 评论(0) 推荐(0) 编辑
摘要:The Fibonacci numbers, commonly denoted F(n) form a sequence, called the Fibonacci sequence, such that each number is the sum of the two preceding one 阅读全文
posted @ 2019-01-22 23:57 Grandyang 阅读(5087) 评论(3) 推荐(1) 编辑
摘要:We have a list of bus routes. Each routes[i] is a bus route that the i-th bus repeats forever. For example if routes[0] = [1, 5, 7], this means that t 阅读全文
posted @ 2019-01-20 05:58 Grandyang 阅读(4668) 评论(3) 推荐(0) 编辑
摘要:In a given integer array A, we must move every element of A to either list B or list C. (B and C initially start empty.) Return true if and only if af 阅读全文
posted @ 2019-01-17 23:56 Grandyang 阅读(4492) 评论(2) 推荐(0) 编辑
摘要:We have jobs: difficulty[i] is the difficulty of the ith job, and profit[i] is the profit of the ith job. Now we have some workers. worker[i] is the a 阅读全文
posted @ 2019-01-14 00:00 Grandyang 阅读(2412) 评论(0) 推荐(0) 编辑
摘要:Some people will make friend requests. The list of their ages is given and ages[i] is the age of the ith person. Person A will NOT friend request pers 阅读全文
posted @ 2019-01-10 23:12 Grandyang 阅读(3233) 评论(0) 推荐(0) 编辑
摘要:A sentence S is given, composed of words separated by spaces. Each word consists of lowercase and uppercase letters only. We would like to convert the 阅读全文
posted @ 2019-01-08 01:36 Grandyang 阅读(2393) 评论(0) 推荐(0) 编辑
摘要:Given an array of unique integers, each integer is strictly greater than 1. We make a binary tree using these integers and each number may be used for 阅读全文
posted @ 2019-01-05 00:00 Grandyang 阅读(2121) 评论(0) 推荐(0) 编辑

Fork me on GitHub