摘要: 题目: Given an input string, reverse the string word by word. For example,Given s = "the sky is blue",return "blue is sky the". 思路: 利用两个stack,一个表示单词,一个表 阅读全文
posted @ 2016-02-11 16:50 很好玩 阅读(297) 评论(0) 推荐(0) 编辑
摘要: 题目: Given an absolute path for a file (Unix-style), simplify it. For example,path = "/home/", => "/home"path = "/a/./b/../../c/", => "/c" click to sho 阅读全文
posted @ 2016-02-11 10:22 很好玩 阅读(374) 评论(0) 推荐(0) 编辑