码迷,mamicode.com
首页 >  
搜索关键字:crazy circuits    ( 312个结果
LA 2031
Mr. White, a fat man, now is crazy about a game named ``Dance, Dance, Revolution". But his dance skill is so poor that he could not dance a dance, eve...
分类:其他好文   时间:2014-05-15 16:57:57    阅读次数:502
FZOJ 1157 Crazy Tea Party
OJ题目:click here~~ 题目分析:1……n按顺序围成一个圈,1与n相邻。交换相邻两个数算1步。至少需要多少步,得到一个逆方向的1……n的圈。 分两半,使用冒泡排序,排成逆序的交换次数之和即为结果。 AC_CODE int f(int n){ return n*(n - 1)/2; } int main(){ int n , t; cin >> t; ...
分类:其他好文   时间:2014-05-06 23:15:55    阅读次数:301
312条   上一页 1 ... 30 31 32
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!