「CF325X」MemSQL start[c] up Round 1

2015年6月16日3,2861
A. Square and Rectangles
模拟题

B. Stadium and Games

\[(2^k-1)m+m(m-1)/2=n\]

枚举k二分得出m

C. Monsters and Diamonds
此题比较恶心QAQ
求最短用个类似dijkstra的东西,如果一种u->{v}的转移所有mn[v]都确定了,把这个转移放进堆
或者是某个转移的代价被更新了
求最长用记忆化搜索,走出环就是inf

D. Reclamation
把图扩展成r*2*c,   增加(i,j)时,同时增加(i,j+c),若(i,j)到(i,j+c)存在一条路经,就有一条环形障碍切断路径
操作用带撤销的并查集实现

E. The Red Button

orz wmd神犇的题解

http://blog.csdn.net/wmdcstdio/article/details/44587751

 

 

avatar
1 Comment threads
0 Thread replies
0 Followers
 
Most reacted comment
Hottest comment thread
0 Comment authors
Recent comment authors
  Subscribe  
提醒
De℃,.: )
De℃,.: )

首页上一个大大的公式感觉好怪……