摘要: (referrence: GeeksforGeeks)Like Merge Sort, Quick Sort is also a divide & conquer problem.It picks an element as pivot and partitions the given array ... 阅读全文
posted @ 2015-10-09 22:52 树獭君 阅读(258) 评论(1) 推荐(0) 编辑
摘要: QuestionDesign and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations:getandset.get(key)- Get ... 阅读全文
posted @ 2015-10-09 11:28 树獭君 阅读(157) 评论(0) 推荐(0) 编辑
摘要: QuestionImplement the following operations of a queue using stacks.push(x) -- Push element x to the back of queue.pop() -- Removes the element from in... 阅读全文
posted @ 2015-10-09 05:36 树獭君 阅读(186) 评论(0) 推荐(0) 编辑
摘要: QuestionImplement the following operations of a stack using queues.push(x) -- Push element x onto stack.pop() -- Removes the element on top of the sta... 阅读全文
posted @ 2015-10-09 02:36 树獭君 阅读(286) 评论(0) 推荐(0) 编辑