2017年6月6日

Maths Intro - Probability

摘要: 设事件A,B,C两辆独立,且满足ABC=空集,及P(A)=P(B)=P(C)=x,求max(x) x最大值为1/2分析: x值要保证所有的由A、B、C交或并得到的集合的概率测度在0到1之间. 先考虑A∪B∪C: P(A∪B∪C)=P(A)+P(B)+P(C)-P(AB)-P(BC)-P(CA)+P( 阅读全文

posted @ 2017-06-06 09:15 fanbird2008 阅读(124) 评论(0) 推荐(0) 编辑

2017年5月26日

DP Intro - Tree DP Examples

摘要: 因为上次比赛sb地把一道树形dp当费用流做了,受了点刺激,用一天时间稍微搞一下树形DP,今后再好好搞一下) 基于背包原理的树形DP poj 1947 Rebuilding Roads 题意:给你一棵树,让你求最少剪掉多少条边可以剪出一棵点数为m的子树. 解法:dp[i][j]表示i节点得到j个节点的 阅读全文

posted @ 2017-05-26 18:26 fanbird2008 阅读(195) 评论(0) 推荐(0) 编辑

DP Intro - Tree POJ2342 Anniversary party

摘要: POJ 2342 Anniversary party (树形dp 入门题) Anniversary party Description There is going to be a party to celebrate the 80-th Anniversary of the Ural State 阅读全文

posted @ 2017-05-26 18:24 fanbird2008 阅读(127) 评论(0) 推荐(0) 编辑

DP Intro - OBST

摘要: http://radford.edu/~nokie/classes/360/dp-opt-bst.html Overview Optimal Binary Search Trees - Problem Problem: Sorted set of keys k1,k2,...,knk1,k2,... 阅读全文

posted @ 2017-05-26 17:07 fanbird2008 阅读(333) 评论(0) 推荐(0) 编辑

DP Intro - Tree DP

摘要: 二叉苹果树 题目 有一棵苹果树,如果树枝有分叉,一定是分2叉(就是说没有只有1个儿子的结点) 这棵树共有N个结点(叶子点或者树枝分叉点),编号为1-N,树根编号一定是1。 我们用一根树枝两端连接的结点的编号来描述一根树枝的位置。下面是一颗有4个树枝的树 2 5 / / 3 4 / / 1 现在这颗树 阅读全文

posted @ 2017-05-26 16:58 fanbird2008 阅读(120) 评论(0) 推荐(0) 编辑

2017年5月25日

DB Intro - MongoDB User

摘要: MongoDB 3.0 用户创建 摘要: MongoDB 3.0 安全权限访问控制,在添加用户上面3.0版本和之前的版本有很大的区别,这里就说明下3.0的添加用户的方法。 环境、测试: 在安装MongoDB之后,先关闭auth认证,进入查看数据库,只有一个local库,admin库是不存在的: ro 阅读全文

posted @ 2017-05-25 19:06 fanbird2008 阅读(171) 评论(0) 推荐(0) 编辑

AWS Intro - Static IP with ssh

摘要: Notes: Please config static ip when launch instance. Because change dynamic public ip to static ip, it will cause ssh connect refused. The way for con 阅读全文

posted @ 2017-05-25 16:34 fanbird2008 阅读(128) 评论(0) 推荐(0) 编辑

SSH Intro - Remove entry

摘要: ssh-keygen -f "/home/frank/.ssh/known_hosts" -R ec2-54-222-218-195.cn-north-1.compute.amazonaws.com.cn 阅读全文

posted @ 2017-05-25 14:34 fanbird2008 阅读(101) 评论(0) 推荐(0) 编辑

2017年5月23日

DB Intro - MongoDB Basic

摘要: mongoDB basic from:http://www.tutorialspoint.com/mongodb prject:https://github.com/chenxing12/l4mongodb Overview MongoDB is a cross-platform, document 阅读全文

posted @ 2017-05-23 18:45 fanbird2008 阅读(218) 评论(0) 推荐(0) 编辑

DB Intro - MongoDB Relations

摘要: https://www.quackit.com/mongodb/tutorial/mongodb_create_a_relationship.cfm 阅读全文

posted @ 2017-05-23 18:20 fanbird2008 阅读(118) 评论(0) 推荐(0) 编辑

导航