链接:http://acm.hdu.edu.cn/showproblem.php?pid=1285
Problem Description
有N个比赛队(1
Input
输入有若干组,每组中的第一行为二个数N(1
Output
给出一个符合要求的排名。输出时队伍号之间有空格,最后一名后面没有空格。
其他说明:符合条件...
分类:
其他好文 时间:
2014-05-10 10:15:18
阅读次数:
323
关于or,and的使用,查资料得知:and相当于then,or相当于else
下面通过举例来理解这两个关键字的使用:
比如:【1】
$isRight or $a=1000;
他与下面这段代码是等价的:
if(isRight==true)
{
}
else
{
$a=1000;
}
【2】
$update and $db_factory=1;
等价于:
if($update=...
分类:
Web程序 时间:
2014-05-10 09:41:00
阅读次数:
452
链接:http://poj.org/problem?id=2421 或 http://acm.hdu.edu.cn/showproblem.php?pid=1102
Problem Description
There are N villages, which are numbered from 1 to N, and you should build some roads ...
分类:
其他好文 时间:
2014-05-10 09:34:09
阅读次数:
389
函数
描述
PHP
addcslashes()
在指定的字符前添加反斜杠。
4
addslashes()
在指定的预定义字符前添加反斜杠。
3
bin2hex()
把 ASCII 字符的字符串转换为十六进制值。
3
chop()
rtrim() 的别名。
3
chr()...
分类:
Web程序 时间:
2014-05-10 09:33:07
阅读次数:
594
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4720
用几何模板,求外接圆,再判断点在不在圆内
#include
#include
#include
const double esp = 1e-9;
//点
struct Point {
double x, y;
Point() {}
Point(double x...
分类:
其他好文 时间:
2014-05-10 08:52:52
阅读次数:
336
这在附另一个转柱形图的效果及代码.
原PHP报表效果:
转成Excel后的效果:
附上代码:
<?php
/**
* PHPExcel
*
* Copyright (C) 2006 - 2014 PHPExcel
*
* This library is free software; you can redistribute it and/or
* modify ...
分类:
Web程序 时间:
2014-05-10 02:19:56
阅读次数:
553
paip.刮刮卡砸金蛋抽奖概率算法跟核心流程.
#---抽奖算法需要满足的需求如下: 1
#---抽奖核心流程 1
#---问题???更好的算法 2
#---实际使用的扩展抽奖算法(带奖品送完判断和每用户最大中奖判断) 2
#-------网上的抽奖算法Php 3
#----java版本的.. 4
参考 5
#---抽奖算法需要满足的需求如下:
1.可以控...
分类:
其他好文 时间:
2014-05-07 08:24:55
阅读次数:
601
题目:
链接:http://acm.hdu.edu.cn/showproblem.php?pid=2087
题意:
给出字符串s1和s2,找出s1中有多少个s2。
算法:
KMP字符串匹配。
思路:
简单,看代码吧。(需要注意的就是字符串用要scanf输入)
代码:
#include
#include
#include
using namespac...
分类:
其他好文 时间:
2014-05-07 04:46:37
阅读次数:
304
http://acm.hdu.edu.cn/showproblem.php?pid=3038
这是一道并查集题目,这并查集感觉好难写,构思花了我很长很长时间,不过打码时间很短。考虑清楚之后明显快多了
#include
#include
#include
#include
#include
#include
#include
#define N 200010
using names...
分类:
其他好文 时间:
2014-05-07 04:03:06
阅读次数:
331