1. [代码]tmpl.js // Simple JavaScript Templating// John Resig - http://ejohn.org/ - MIT Licensed(function() {var cache = {};this.tmpl = function tmpl(s....
分类:
编程语言 时间:
2014-07-09 19:19:15
阅读次数:
290
简单工厂模式是由一个工厂对象来决定创建出哪一种产品类的实例(对象),就是由一个工厂类根据传入的参数来决定需要创建哪一种产品的对象或实例。
此模式主要涉及到工厂角色,抽象产品,具体产品三个角色
工厂类(Creator),此模式的核心,含有与应用紧密相关的商业逻辑,
抽象产品(Product),担任需要创建产品的父类,一般由一个java接口事抽象类来实现
具体产品(Concrete Produ...
分类:
其他好文 时间:
2014-07-09 12:18:01
阅读次数:
187
Help Me with the Game
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 3292
Accepted: 2122
Description
Your task is to read a picture of a chessboard posi...
分类:
其他好文 时间:
2014-07-09 11:58:32
阅读次数:
204
Problem D
Prince and Princess
Input: Standard Input
Output: Standard Output
Time Limit: 3 Seconds
In an n x n chessboard, Prince and Princess plays a game. The squares in the chessboard are ...
分类:
其他好文 时间:
2014-07-09 11:44:54
阅读次数:
211
Just a Hook
Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 15889 Accepted Submission(s): 7897
Problem Description
In the game o...
分类:
其他好文 时间:
2014-07-09 11:35:08
阅读次数:
215
3882 - And Then There Was One
Time limit: 3.000 seconds
Let's play a stone removing game.
Initially, n stones are arranged on a circle and numbered
1,..., n clockwise (Figure 1). You are also...
分类:
其他好文 时间:
2014-07-09 10:00:13
阅读次数:
172
Designing a Class Interface
设计类接口
The Objective-C syntax for creating a class is very simple. It typically comes in two parts.
创建类的语法是很简单的,通常包括两部分。
The class interface is u...
分类:
其他好文 时间:
2014-07-08 16:24:27
阅读次数:
168
Flip Game
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 29713
Accepted: 12876
Description
Flip game is played on a rectangular 4x4 field with two-sided...
分类:
其他好文 时间:
2014-07-08 13:32:49
阅读次数:
189
The Pilots Brothers' refrigerator
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 18040
Accepted: 6841
Special Judge
Description
The game “The Pilots...
分类:
其他好文 时间:
2014-07-08 12:54:14
阅读次数:
131
原题: ZOJ 3686http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3686这题本来是一个比较水的线段树,结果一个mark坑了我好几个小时。。哎。太弱。先DFS这棵树,树形结构转换为线性结构,每个节点有一个第一次遍历的时间...
分类:
其他好文 时间:
2014-07-08 00:46:56
阅读次数:
295