码迷,mamicode.com
首页 >  
搜索关键字:a1    ( 6114个结果
POJ 2356 Find a multiple 鸽巢原理
题目来源:POJ 2356 Find a multiple 题意:n个数 选出任意个数 使得这些数的和是n的倍数 思路:肯定有解 并且解是连续的一段数 证明: 假设有m个数 a1,a2,a3...am    s1 s2 s3...sm为前缀和 s1 = a1 s2 = a1+a2 s3 = a1+a2+a3... sm = a1+a2+a3+...+am 1.如果某个前缀和si%m =...
分类:其他好文   时间:2014-08-02 21:01:54    阅读次数:312
正则表达式
Q1.EmEditor中转换C#注释的显示格式,由三行显示成一行1 /// 2 /// 対象期間3 /// 原来格式1 /// 対象期間现在格式A1.使用编辑器的替换功能,Find:///\s*\r\n.+///\s*(.+)\r\n....
分类:其他好文   时间:2014-08-02 18:08:43    阅读次数:201
Codeforces Round #259 (Div. 2) B. Little Pony and Sort by Shift(模拟)
题目链接:Codeforces Round #259 (Div. 2)  B. Little Pony and Sort by Shift 求给出的序列最少移动多少次成为非下降序列。移动方式:只能将最后一个元素移到第一个位置 即:a1,?a2,?...,?an?→?an,?a1,?a2,?...,?an?-?1. 从后前开始搜非下降的子序列,然后前面的子序列接在其后面,最后判断变化后的...
分类:其他好文   时间:2014-08-02 15:40:43    阅读次数:273
【HackerRank】Sherlock and Array
Watson gives an array A1,A2...AN to Sherlock. Then he asks him to find if there exists an element in the array, such that, the sum of elements on its ...
分类:其他好文   时间:2014-08-02 12:36:13    阅读次数:185
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!