2014年1月7日

Codeforces 300C

摘要: 题目链接: http://codeforces.com/contest/300/problem/C本来是道不难的题目,还是自己的数学功底不扎实。从该题又一次巩固了关于乘法逆的概念,在剩余系中,如果要做除法,如 a / b%n , 此时应该计算 a * (b在n下的逆), 而不是直接计算 a / b另... 阅读全文

posted @ 2014-01-07 19:24 Stomach_ache 阅读(222) 评论(0) 推荐(0) 编辑

初次接触python的re模块

摘要: 刷CF的时候,看到一个简单的题目,可以用来练练正则表达式于是乎找到了re.sub的用法,说明如下re.sub: (pattern, repl, string, count=0, │ flags=0) │ Return the string obtained by replacing the left... 阅读全文

posted @ 2014-01-07 10:13 Stomach_ache 阅读(151) 评论(0) 推荐(0) 编辑

导航