码迷,mamicode.com
首页 >  
搜索关键字:implement stack usin    ( 11956个结果
LeetCode OJ - LRU Cache
题目: Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations:getandset. get(key)- Get ...
分类:其他好文   时间:2014-05-16 05:42:29    阅读次数:280
uva 101 - The Blocks Problem
用 栈 stack 来模拟 题目意思:http://blog.csdn.net/mobius_strip/article/details/12765319 下面的代码有坑,输出格式需要调。 #include #include #include #include #include using namespace std; const int maxn=25+5; stacks[maxn]; i...
分类:其他好文   时间:2014-05-15 07:22:04    阅读次数:273
[LeetCode]String to Integer (atoi)
Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do not see below and ask yourself what are the possible input cases. Notes: It is intended for this problem to be specifi...
分类:其他好文   时间:2014-05-15 05:00:50    阅读次数:229
Call back function implement
Call back function easily implement     #include void HelloWorld(int nIndex) { printf("%d person say Hello World\n",nIndex); } void MyName(int len) { printf...
分类:其他好文   时间:2014-05-15 04:21:05    阅读次数:270
JBoss VS Tomcat
JBoss (JBoss 已经重新命名了,新版的称之为WildFly)提供了完全Java企业版协议栈( JavaEnterprise Edition (JEE) stack),企业级的Java Bean以及其它有用的功能特性。而JBoss和Tomcat都包含Servelt Engine 和Web Server服务。Tomcat相对于JBoss而言,比较轻量级的Web服务器,它没有太多的资源和Jav...
分类:其他好文   时间:2014-05-15 04:10:17    阅读次数:351
LeetCode 010 Regular Expression Matching
【题目】 Implement regular expression matching with support for '.' and '*'. '.' Matches any single character. '*' Matches zero or more of the preceding element. The matching should cover the entire input string (not partial). The function prototype shoul...
分类:其他好文   时间:2014-05-14 21:36:52    阅读次数:348
LeetCode 008 String to Integer (atoi)
【题目】 Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do not see below and ask yourself what are the possible input cases. Notes: It is intended for this problem to be s...
分类:其他好文   时间:2014-05-14 21:00:57    阅读次数:304
Stack Overflow创始人分享:如何促使团队紧密协作
会议是浪费工作时间的最佳去处 今天你开了多少个会?这个星期呢?这个月呢?再自问一下,那些会议中有多少是值得参加的?如果把相同的时间用在工作上,你又能完成多少事情?我们究竟为什么要开会? 尽管有些会议是不可避免的,甚至是必需的。我们应该以怀疑的态度去看待会议,把它当成是一种降低工作效率的风险。事实上,会议往往只是在浪费宝贵的工作时间。就我而言,我采用以下几个原则,以确保我的会议是真正有用...
分类:其他好文   时间:2014-05-14 14:53:31    阅读次数:256
解决postgis中.shp格式导入到postgis中.dbf can not be opened的问题
按要求装了postgreSQL 9.3,之前装个9.2.数据库出错了,选择了9.3版本。然后通过Application stack bulider装了 postgis 2.1。装的时候选择了创建一个空的数据库,但屡屡安装失败,取消之后安装成功。     配置了数据库的参数后,选择要导入的.shp文件,更改SRID,这里其实SRID我不太了解,因为每个SRID对应的都对应EPGS编码,打开prj文...
分类:数据库   时间:2014-05-14 14:23:55    阅读次数:1219
Leetcode: Trapping Rain Water
这道题做的比较艰辛,一开始自己想的是一个用stack的解法,感觉过于繁琐(出栈,入栈,计算容积),但未尝不是一个好的尝试,这个方法还是有点小问题,过后会好好想清楚。看了网上提示完成了最终的方法,这个方法两次遍历数组,第一次遍历找每个元素右边最大的元素,第二次遍历寻找每个元素左边最大的元素,同时计算该...
分类:移动开发   时间:2014-05-14 11:03:34    阅读次数:412
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!