- 博客(4)
- 收藏
- 关注
原创 单例模式
一、定义设计模式:一种设计思想,针对不同的业务场景,用不同的方式去设计代码结构,其最最本质的目的是为了解耦,延伸一点的话,还有为了可扩展性和健壮性,但是这都是建立在解耦的基础之上。单例模式:是一种常用的软件设计模式,单例对象的类必须保证只有一个实例存在。保证一个类仅有一个实例,并提供一个访问他的全局访问点,该实例被所有程序模块共享。二、单例模式构造public class Singleton { ...
2018-03-19 20:31:02
206
原创 【Monotonic-queue】【dp】【Segment-tree】【STL】Codeforces 487B - Strip
Describtion: Alexandra has a paper strip with n numbers on it. Let's call them ai from left to right. Now Alexandra wants to split it into some pieces (possibly 1). For each piece of strip, it
2016-03-06 00:48:36
802
原创 【单调队列】HDU4193
HDU4193:http://acm.hdu.edu.cn/showproblem.php?pid=4193 题目描述:有一串数列:a1,a2,a3,a4 .. an, 它可以变形为 a2,a3,a4 .. an,a1 ; a3,a4 .. an,a1,a2 ; a4 .. an,a1,a2,a3
2016-03-04 15:32:20
295
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅