随笔分类 -  Leetcode | Stack&Queue

摘要:问题描述Given an absolute path for a file (Unix-style), simplify it.For example,path="/home/", =>"/home"path="/a/./b/../../c/", =>"/c"click to show corner... 阅读全文
posted @ 2015-08-18 15:33 Chapter 阅读(214) 评论(0) 推荐(0)
摘要:问题描述Given n non-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in the ... 阅读全文
posted @ 2015-08-02 10:00 Chapter 阅读(150) 评论(0) 推荐(0)
摘要:问题描述Given an arraynums, there is a sliding window of sizekwhich is moving from the very left of the array to the very right. You can only see theknumb... 阅读全文
posted @ 2015-07-19 10:50 Chapter 阅读(213) 评论(0) 推荐(0)
摘要:问题描述Implement a basic calculator to evaluate a simple expression string.The expression string may contain open ( and closing parentheses ), the plus +... 阅读全文
posted @ 2015-07-15 12:26 Chapter 阅读(185) 评论(0) 推荐(0)
摘要:问题描述:Implement the following operations of a stack using queues.push(x) -- Push element x onto stack.pop() -- Removes the element on top of the stack.... 阅读全文
posted @ 2015-06-16 10:35 Chapter 阅读(190) 评论(0) 推荐(0)