自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(24)
  • 资源 (5)
  • 收藏
  • 关注

原创 配置LuaRocks

配置LuaRocks需要指定LuaRocks的LuaJIT,所以需要利用--with-lua-include=这个选项,由于我的Lua环境是跟openresty一起安装的,所以我的luaJIT的路径在openresty的安装文件夹中。

2013-08-29 15:40:14 1284

原创 配置openresty

由于公司测试机只有改变个人文件夹的权限,导致安装openresty竟然用了一天的时间!首先,要按照官网的流程进行安装,不过执行configure脚本的时候,由于它默认要安装到/usr/local/openresty目录中,由于没有其他文件夹的权限,所以一定要在使用./configure --prefix=    这个选项来指定安装的路径(就是因为他我总在后续的步骤中安装失败....)。

2013-08-23 15:13:53 1029

原创 35:Video Surveillance

A friend of yours has taken the job of security officer at the Star-Buy Company, a famous department store. One of his tasks is to install a video surveillance system to guarantee the security of the

2013-04-29 21:00:57 950

原创 34:E ·Power Network(最大流算法-----压入重标法篇)

算法分析部分转自该博客:点击打开链接与Ford-Fulkerson方法不同,压入和重标记算法不是检查整个残留网络来找出增广路径,而是每次仅对一个顶点进行操作,并且仅检查残留网络中该顶点的相邻顶点。压入和重标记算法引入了一个新的概念叫做余流,余流的定义为e(u)=f(V,u)。我们知道,在流网络满足三个限制条件的情况下有e(u)=0,但是在该算法的执行过程中,并不能保证流守恒,但

2013-04-29 00:16:15 812

原创 34:E ·Power Network(最大流基础算法篇)

A power network consists of nodes (power stations, consumers and dispatchers) connected by power transport lines. A node u may be supplied with an amount s(u)³0 of power, may produce an amount 0£p(u)£

2013-04-27 23:59:54 630

原创 32:C·Non-Decreasing Digits

C ·Non-Decreasing DigitsA number is said to be made up of non-decreasing digits if all the digits to the left of any digit is less than or equal to that digit. For example, the four-digit number 1

2013-04-14 19:28:48 737

原创 31:B ·Nim-B* Sum

B ·Nim-B* SumNIM is an ambigram . The game of NIM is played with any number of piles of objects with any number of objects in each pile. At each turn, a player takes one or more (up to all) object

2013-04-14 09:22:58 709

原创 24:Minimum Sum

DescriptionYou are given N positive integers, denoted as x1, x2 ... xN. Then give you some intervals [l, r]. For each interval, you need to find a number x to make |x-xl| + |x-x2| + … + |x

2013-04-12 08:25:10 632

原创 23:Easy problem

DescriptionThereis N pairs of balls in a small box. That means the number for eachpair is the same. However, for some reason, a ball is lost. Now, youwill get the number of the rest. Can

2013-04-09 15:07:45 522

原创 19:卡片(即POJ 1091)

Description在一张卡片上面,有N+1个正整数,最后一个数是M,而前N个数都不超过M,设为a1,a2, a3, …, aN, 问是否存在整数x1,x2, x3, …, xN, x(N+1),满足x1*a1 + x2*a2 +...+ xN*aN +x(N+1)*M = 1。当确定N和M后,显然一共有M^N张不同的卡片。现在的问题是,在这所有的卡片中,

2013-04-08 20:18:22 852

原创 18:Intersection

DescriptionYouare to write a program that has to decide whether a given linesegment intersects a given rectangle. An example: line:start point: (4,9) end point: (11,2) rectangl

2013-04-08 19:48:49 470

原创 16:棋盘分割

Description将一个8*8的棋盘进行如下分割:将原棋盘割下一块矩形棋盘并使剩下部分也是矩形,再将剩下的部分继续如此分割,这样割了(n-1)次后,连同最后剩下的矩形棋盘共有n块矩形棋盘。(每次切割都只能沿着棋盘格子的边进行)原棋盘上每一格有一个分值,一块矩形棋盘的总分为其所含各格分值之和。现在需要把棋盘按上述规则分割成n块矩形棋盘,并使各矩形棋盘总分的

2013-04-08 19:38:34 540

原创 15:Panic Room

DescriptionYou are the lead programmer for the Securitron 9042, the latest and greatest in home security software from Jellern Inc. (Motto: We secure your stuff so YOU can't even get to it). T

2013-04-06 21:28:00 594

原创 14:Labeling Balls

DescriptionWindy hasNballs of distinct weights from 1 unit toNunits. Now he tries to label them with 1 toNin such a way that:No two balls sharethe same label.The labeli

2013-04-06 21:08:25 681

原创 13:K-based Numbers

DescriptionLet’sconsiderK-basednumbers, containing exactly Ndigits. We define a number to be valid if its K-basednotation doesn’t contain two successive zeros. For example: 10102

2013-04-06 20:32:48 839

原创 12:Heavy Cargo

DescriptionBig Johnsson Trucks Inc. is a company specialized in manufacturing big trucks. Their latest model, the Godzilla V12, is so big that the amount of cargo you can transport with it is neve

2013-04-06 20:07:42 806

原创 10:Rpg Game

Description There are n cells in a sequence. You can use three kinds of colors, red , pink , green to paint these cells , one cell with only one kind of color . Promising that any two adjacent cel

2013-03-29 11:31:53 509

原创 9:Maximum sum

DescriptionGiven a set of n integers: A={a1, a2,..., an}, we define a function d(A) as below:d(A)=sum{a[s1]~a[t1]}+sum{a[s2]~a[t2]}The rule is 1Your task is to calculate d(A).InputThe in

2013-03-29 11:22:14 644

原创 8:Rightmost Digit

Problem DescriptionGiven a positive integer N, you should output the most right digit of N^N. InputThe input contains several test cases. The first line of the input is a single integer T which

2013-03-29 10:48:50 573

原创 7:Fence Repair

DescriptionFarmer John wants to repair a small length of the fence around the pasture. He measures the fence and finds that he needs N  (1 ≤ N ≤ 1,000)) planks of wood, each having some integer le

2013-03-29 10:30:21 578

原创 6:Flip Game

DescriptionFlip game is played on a rectangular 4x4 field with two-sided pieces placed on each of its 16 squares. One side of each piece is white and the other one is black and each piece is lying e

2013-03-29 10:04:41 1202

原创 5:Permutation

Description We all know that , when there are n positive integers (namely 1…n) , we can use these n integers to construct n! kinds of permutations . Sort these permutations in lexicographic order

2013-03-29 10:00:58 558

原创 2:A-B Problem

DescriptionCalculate A-BInputTwo decimal integers a and b(-10^100 < a,b < 10^100) in one line, separated by one space.OutputOutput a-b in one line.Sample Input1 2Sample Out

2013-03-29 08:58:31 596

原创 1:A+B Problem

DescriptionCalculate a+bInputTwo integer a,b (0OutputOutput a+bSample Input1 1Sample Output2package OJ;import java.util.*;public class P1 { /** * @param

2013-03-29 08:51:59 567

JAVA 精华 区 相当不错的东西哦

Java啊 必须都是好东西 相当有用 啊

2010-10-19

C++设计新思维(泛型编程与设计模式之应用)

C++设计新思维(泛型编程与设计模式之应用) 质量相当不错啊

2010-09-04

C++编程实用算法的分析与程序设计

实用算法的分析与程序设计 相当不错的电子书啊

2010-09-04

《Google Android 开发入门与实战》第8章 移动信息仓库—Android的数据存储操作

android教程 比较详细的电子书 保证质量

2010-09-04

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除