码迷,mamicode.com
首页 > 其他好文
strStr
For a given source string and a target string, you should output the first index(from 0) of target string in source string. If target does not exist i ...
分类:其他好文   时间:2016-07-06 09:54:02    阅读次数:123
Best Time to Buy and Sell Stock with Cooldown
lastSell = sell is after buy max. So the buy price is compared with sell[i-2]. Current sell is sell[i-1]. ...
分类:其他好文   时间:2016-07-06 09:55:58    阅读次数:116
Extend Volume 操作 - 每天5分钟玩转 OpenStack(56)
今天讨论如何扩大 volume 的容量。为了保护现有数据,cinder 不允许缩小 volume。 ...
分类:其他好文   时间:2016-07-06 09:53:09    阅读次数:130
Hardcore和Bauble
搞科研的时候,如果搞的是核心,我们可以说搞得是hardcore, 如果搞得是不起眼的小东西,可以说是baulbe。 Hardcore 1,adj. 核心部分, 中坚分子, 绝对的, 无条件的, 没有限制的。 2,adj. (黄色作品)赤裸裸描写性行为的 Bauble n. 小玩意;华而不实的小件装饰 ...
分类:其他好文   时间:2016-07-06 09:53:37    阅读次数:131
geeksforgeeks@ Largest Number formed from an Array
http://www.practice.geeksforgeeks.org/problem-page.php?pid=380 Largest Number formed from an Array Given a list of non negative integers, arrange them ...
分类:其他好文   时间:2016-07-06 09:53:26    阅读次数:195
Docker: adding a file from a parent directory
17down votefavorite 4 In my Dockerfile I've got : ADD ../../myapp.war /opt/tomcat7/webapps/ That file exists as ls ../../myapp.war returns me the corr ...
分类:其他好文   时间:2016-07-06 09:53:59    阅读次数:949
Minimum Height Trees
1. Check boundary case that when n == 1. There is only one node (0) 2. Set can access by iterator. ...
分类:其他好文   时间:2016-07-06 09:52:51    阅读次数:178
Burst Balloons
1. Make final balloon as the position i. 2. try to optimize the solution from (left , i - 1) to (i + 1, right). 3. Since it garantee to cover i positi ...
分类:其他好文   时间:2016-07-06 09:52:12    阅读次数:92
Ugly Number | & || & |||
Ugly Number Write a program to check whether a given number is an ugly number`. Ugly numbers are positive numbers whose prime factors only include 2,  ...
分类:其他好文   时间:2016-07-06 09:54:34    阅读次数:197
Digit Counts
Count the number of k's between 0 and n. k can be 0 - 9. Count the number of k's between 0 and n. k can be 0 - 9. Count the number of k's between 0 an ...
分类:其他好文   时间:2016-07-06 09:52:13    阅读次数:180
A + B Problem
Write a function that add two numbers A and B. You should not use + or any arithmetic operators. 分析: 典型的Bit Operation. ...
分类:其他好文   时间:2016-07-06 09:51:45    阅读次数:150
网易云音乐高品质音乐引用
仅限您个人的博客、网页,请勿分享发布到大型网站、贴吧等地 http://ikdm.tk/labs/163/ HTML5示例 Flash 示例1(来自豆瓣播放器,单文件播放) Flash 示例2(多文件播放) ...
分类:其他好文   时间:2016-07-06 09:52:47    阅读次数:235
【我的《冒号课堂》学习笔记】设计原则(3)内聚原则
内聚原则 “高内聚,低耦合”原则是软件模块设计的通用原则。实际上,该原则最早出现在结构化设计(structured design)中,后被引入对象式设计。耦合和内聚是衡量软件设计质量的两个重要指标,是检验模块设计是否合理的主要标准。其中,耦合(coupling)反映模块之间的关联程度,内聚(cohe ...
分类:其他好文   时间:2016-07-06 09:53:15    阅读次数:128
Trailing Zeros
Write an algorithm which computes the number of trailing zeros in n factorial. Have you met this question in a real interview? Yes Write an algorithm ...
分类:其他好文   时间:2016-07-06 09:50:44    阅读次数:131
【我的《冒号课堂》学习笔记】设计原则(2)依赖原则
依赖原则 间接原则有一个直接的推论,就是依赖反转原则(Dependency Inversion Principle),简称DIP。依赖反转原则就是高层模块不应依赖低层模块,它们都应依赖抽象;抽象不应依赖细节,细节应依赖抽象。 1)DIP的产生背景 从代码实现的角度来看,高层模块依赖低层模块是很正常的 ...
分类:其他好文   时间:2016-07-06 09:52:38    阅读次数:234
【SSH系列】静态代理&&动态代理
代理模式是二十三中设计模式中的一种,代理模式就是指由一个代理主题来操作真实的主题,真实的主题执行具体的业务操作,而代理主题负责其她相关业务,简而言之,代理模式可以由以下三个部分组成: a、抽象角色:通过接口或抽象类声明真实角色实现的业务方法。 b、代理角色:实现抽象角色,是真实角色的代理,通过真实角色的业务逻辑方法来实现抽象方法,并可以附加自己的操作。 c、真实角色:实现抽象角色,定义真实角色所要...
分类:其他好文   时间:2016-07-06 01:54:06    阅读次数:422
动态规划和子结构的浅谈
我们先看看之前的代码。这是一个 斐波那契数列 我们知道这个代码的执行会有很多重叠的子结构。 让我们先看下图{我今天不用笔画了 LOL} {感谢ProcessOn,我也能画个能看的图了} 我们从上图看到 产生和很多重叠的子结构,重复运算了很多已经算过了,这就比较尴尬了。 这个时候我们要提下动态规划了: ...
分类:其他好文   时间:2016-07-06 01:52:45    阅读次数:191
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!