题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4822Problem DescriptionThree countries, Red, Yellow, and Blue are in war. The map of battlefield is a t...
分类:
其他好文 时间:
2014-08-16 16:19:50
阅读次数:
275
Given an array with n objects colored red, white or blue, sort them so that objects of the same color are adjacent, with the colors in the order red, white and blue.
Here, we will use the integers ...
分类:
其他好文 时间:
2014-08-16 12:35:30
阅读次数:
233
Every culture has its own etiquette red lines that tourists frequently aren’t aware they’re crossing. It doesn’t matter where you travel—you should ne...
分类:
其他好文 时间:
2014-08-15 17:17:39
阅读次数:
227
public IBalloonCallout CreateBallonCallout(double x, double y) { IRgbColor pRgbClr = new RgbColorClass(); pRgbClr.Red = ...
分类:
其他好文 时间:
2014-08-14 16:12:49
阅读次数:
244
初学前端,正在做一个项目,发现浏览器兼容问题,然后上网搜了一下,网上有很多整理的解决方法,为了以后自己看着方便,现在自己也整理一下。1 css的hack知识/* CSS属性级Hack */ color:red; /* 所有浏览器可识别*/ _color:red; /* 仅IE6 识别 */ *col...
分类:
Web程序 时间:
2014-08-14 13:58:38
阅读次数:
275
题目链接:http://poj.org/problem?id=1979思路:典型的搜索题,个人感觉广搜深搜皆可以,我用深搜做的。代码: #include using namespace std;int startx,starty;//开始的位置 int n,m;//行数和列数 char e[21]....
分类:
其他好文 时间:
2014-08-14 10:29:28
阅读次数:
245
创建 Array 的基本方式有两种。第一种是使用 Array 构造函数,如下所示:var colors = new Array(); 也可以如下,如下代码创建了一个包含3个字符串值的数组:var colors = new Array("red","green","blue"); 创建 Arr...
分类:
Web程序 时间:
2014-08-14 00:56:07
阅读次数:
187
Red and Black
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 9732 Accepted Submission(s): 6060
Problem Description
There is a r...
分类:
其他好文 时间:
2014-08-13 22:41:37
阅读次数:
452
题意:一共有四个方向,从’@‘出发,找能到达‘.’的个数, #是不能通过的.
策略:广搜。
这道题属于最简单的bfs了。
代码:
#include
#include
#include
using std::queue;
bool vis[25][25];
char s[25][25];
int n, m;
int ans = 0;
struct node{
int x, y;
};
no...
分类:
其他好文 时间:
2014-08-13 22:31:17
阅读次数:
301
在UBUNTU中vim的配置文件存放在/etc/vim目录中,配置文件名为vimrc 在Fedora中vim的配置文件存放在/etc目录中,配置文件名为vimrc 在Red Hat Linux 中vim的配置文件存放在/etc目录中,配置文件名为vimrc set nocompatible "去掉有...
分类:
其他好文 时间:
2014-08-13 22:17:37
阅读次数:
356