一名苦逼的OIer,想成为ACMer

Iowa_Battleship

2018年12月6日

洛谷1007 独木桥

摘要: "原题链接" 水题。 因为全部人走路速度是一样的,所以当两个人相遇时转身走就相当于与直接穿过去。 因此每个人都是独立的,而每个人开始有两个方向去走,取个$max$和$min$就好。 cpp include using namespace std; inline int re() { int x = 阅读全文

posted @ 2018-12-06 21:11 Iowa_Battleship 阅读(108) 评论(0) 推荐(0) 编辑

洛谷1004 方格取数

摘要: "原题链接" ~~继续写水题中~~ $DP$水题。 不过费用流解更灵活,可以解决$k$条路。 所以就写了个费用流。 cpp include include using namespace std; const int N = 1e4 + 10; int fi[N], ne[N], da[N], di 阅读全文

posted @ 2018-12-06 20:48 Iowa_Battleship 阅读(123) 评论(0) 推荐(0) 编辑

导航