自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(10)
  • 收藏
  • 关注

转载 Java中的DatagramPacket与DatagramSocket的初步

转载于:http://blog.csdn.net/pengchua/article/details/4398972 1.基本概念:   a.DatagramPacket与DatagramSocket位于java.net包中   b.DatagramPacket表示存放数据的数据报,DatagramSocket表示接受或发送数据报的套接字   c.由这两个类所有构成的网络链接是基于UDP协议

2016-01-29 14:09:34 340

转载 Java网络编程入门

转载于:http://www.cnblogs.com/springcsc/archive/2009/12/03/1616413.html 网络编程          网络编程对于很多的初学者来说,都是很向往的一种编程技能,但是很多的初学者却因为很长一段时间无法进入网络编程的大门而放弃了对于该部分技术的学习。          在 学习网络编程以前,很多初学者可能觉得网络编程是比较

2016-01-27 23:12:51 188

转载 hdu 2050

转载于:http://www.cnblogs.com/chaosheng/archive/2012/01/26/2329583.html (1) n条直线最多分平面问题       题目大致如:n条直线,最多可以把平面分为多少个区域。       析:可能你以前就见过这题目,这充其量是一道初中的思考题。但一个类型的题目还是从简单的入手,才容易发现规律。当有n-1条直线时,平面最多被分成了

2016-01-22 18:23:32 327

原创 hdu 1864 01背包

分析:因为报销的额度是小数,所以把总共符合要求的发票数作为背包容量,报销金额作为价值,最后再扫一遍,找到在给定报销金额范围内最大的金额: #include #include #include #include using namespace std; double d[30009]; double w[39]; int main() { double Q; int n,m;

2016-01-22 12:04:24 215

原创 hdu 2899 二分+数学

分析:要找一个值最小的,对F(X)求导,再求导,发现二阶导恒大于0,那么说一阶导数单调递增,所以说要找F‘(x)=0的点,这样的话就是最小值 #include #include #include #include #include #include #include #include #include #define INF 10e7 using namespace std

2016-01-21 16:40:01 331

原创 hdu 2199 高精度二分模板

#include #include #include #include #include #include #include #include #include #define INF 10e7 using namespace std; const int maxn=505; double deal(double x) { return 8*pow(x,4)+7*pow(x,3)

2016-01-21 16:02:33 295

原创 NYOJ 246 Human Gene Functions dp

分析: 状态转移方程 d[i][j]=max( d[i-1][j-1]+val[a[i]][b[j]] , d[i-1][j]+val[a[i]][-] , d[i][j-1]+val[-][bb[j]] ); 注意边界初始化。 #include #include #include #include #include #include #include using namespace s

2016-01-20 11:26:10 263

转载 C++中数字与字符串之间的转换

1、字符串数字之间的转换 (1)string --> char *    string str("OK");    char * p = str.c_str(); (2)char * -->string    char *p = "OK";    string str(p); (3)char * -->CString     char *p ="OK";    CSt

2016-01-17 20:55:06 514

原创 HOJ 2706 Key Task

—题目:http://acm.hit.edu.cn/hoj/problem/view?id=2706 题目描述:可怜的大学生被困在迷宫里了,迷宫里有B、Y、G、R 四种门,也有b、y、g、r四种钥匙,对应的钥匙可以打开对应的门。迷宫有多个出口。问,如果大学生每步可以上下左右移动。那么他最少用多少不可以从迷宫中解脱,或者一辈子被困在迷宫中。 分析:一共有四把钥匙,所以还需加一维数组来保存状态。

2016-01-16 15:50:39 100

原创 Codeforces 598D Igor In the Museum (dfs)

Igor is in the museum and he wants to see as many pictures as possible.Museum can be represented as a rectangular field of n × m cells. Each cell is either empty or impassable. Empty cells are marked

2016-01-16 14:47:08 400

空空如也

空空如也

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

TA关注的人

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