摘要: Design and implement a data structure for a compressed string iterator. It should support the following operations: next and hasNext. The given compre 阅读全文
posted @ 2017-07-10 23:31 Jimmy_Cheng 阅读(528) 评论(0) 推荐(0) 编辑
摘要: Given a stream of integers and a window size, calculate the moving average of all integers in the sliding window. For example, MovingAverage m = new M 阅读全文
posted @ 2017-07-10 05:34 Jimmy_Cheng 阅读(652) 评论(0) 推荐(0) 编辑
摘要: Given a nested list of integers, return the sum of all integers in the list weighted by their depth. Each element is either an integer, or a list -- w 阅读全文
posted @ 2017-07-10 01:27 Jimmy_Cheng 阅读(311) 评论(0) 推荐(0) 编辑