Python
肖冬禹想要拿OFFER
人生已如此悲惨,只求能去湾区养老。。。
展开
-
Python 迭代器和生成器的区别
常见基础问题,老忘,写一波提醒自己。1. 首先,要了解什么是Iterables。我们常常这么写一个遍历打印程序,一个一个来读取元素的值。>>> mylist = [1, 2, 3]>>> for i in mylist:... print(i)123基本上for ....... in ........这种结构都适用于Iterable...原创 2019-03-09 02:56:08 · 375 阅读 · 0 评论 -
leetcode 621. Task Scheduler
Given a char array representing tasks CPU need to do. It contains capital letters A to Z where different letters represent different tasks. Tasks could be done without original order. Each task could ...原创 2019-03-27 06:21:15 · 178 阅读 · 0 评论 -
416. Partition Equal Subset Sum
Given anon-emptyarray containingonly positive integers, find if the array can be partitioned into two subsets such that the sum of elements in both subsets is equal.Note:Each of the array eleme...原创 2019-03-27 13:24:03 · 168 阅读 · 0 评论