自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

  • 博客(14)
  • 收藏
  • 关注

原创 常用的vim插件及vimrc备份

1. taglist下载地址: http://www.vim.org/scripts/script.php?script_id=2732. syntastic. 语法检查插件。下载地址: http://www.vim.org/scripts/script.php?script_id=27363. NERD commenter. 注释插件。下载地址: http

2014-02-03 18:22:47 1032

原创 POJ挑战赛3(POJ Challenge Round 3)题解

这次的POJ挑战赛难度下降了,难得遇到自己都能做出来的比赛,写个题解攒人品吧...A. table题目链接: http://poj.openjudge.cn/practice/1059/有a张三角形桌子和b张正方形桌子,以及有n个小组,每个小组有Si个学生。一个小组可以选出一些桌子拼在一起供他们使用,且一个拼起来的桌子块周围能坐下的最多的人数为这个桌子块的周长。问最多能使多少个小组

2013-11-13 22:10:39 2024

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(8)

Part 8. Problem 71 - Problem 80.前几天把暑假剩的两道题过了,把cody challenge搞完了。最近快放国庆了,又有大段空闲时间了,白天学学算法,晚上把这个坑填了...后面这些代码都重写了。Problem 71. Read a column of numbers and interpolate missing data

2013-09-29 00:33:37 2736

原创 Codeforces Round #198 (Div. 1)

Problem A. Tourist Problem给出一些坐标点{ai}, 起始点在a = 0处,问按顺序经过所有点的所有可能路径的平均长度是多少。先算从起始点到第一点所有可能的距离之和,为sum(a[1..n])*(n - 1)!。再算所有可能的|ai - aj|的和。总的可能的|ai - aj|状态数有(n-1)*n!,按ai在aj前面进行分类,可以分n(n-1)类,所以每一个

2013-09-01 22:47:15 826

原创 Codeforces Round #197 (Div. 2)

好久没做CF了,前两天心血来潮做了一场Div2,找找手感...Problem A. Helpful Maths给一个只有加号和数字123的算式,将数字排序后输出。#include #include #include using namespace std;int main(){ char s[200]; while (~scanf("%s", s)) { vect

2013-08-28 23:57:35 555

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(7)

Part 7. Problem 61 - Problem 70.Problem 61. Find state names that end with the letter A% Given a list of US states, remove all the states that end with the letter A.% % Example:% % Input s1

2013-08-27 22:06:04 3024

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(6)

Part 6. Problem 51 - Problem 60.Problem 51. Find the two most distant points% Given a collection of points, return the indices of the rows that contain the two points most distant from one another

2013-08-25 18:36:14 2331

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(5)

Part 5. Problem 41 - Problem 50.Problem 41. Cell joiner% You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string from the ce

2013-08-24 22:54:05 2668

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(4)

Part 4. Problem 31 - Problem 40.Problem 31. Remove all the words that end with "ain" % Given the string s1, return the string s2 with the target characters removed.% % For example, given% %

2013-08-23 22:32:43 2643

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(3)

Part 3. Problem 21 - Problem 30Problem 21. Return the 3n+1 sequence for n% A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the numb

2013-08-22 23:28:39 3308

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(2)

Problem 11. Back and Forth Rows% Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 wind back and forth along the rows as shown in the examples below.% % Examples:% %

2013-08-21 20:40:50 2875

原创 [matlab]mathworks上的cody challenge题解及一些常用函数的总结(1)

暑假想练一下matlab,就想像练C++一样找一个可以刷题的OJ。很幸运的是,matlab官网上就有:http://www.mathworks.com/matlabcentral/cody花了些时间刷了一下上面的入门题(Problem Groups里面的Cody Challenge),基本上都是模拟题。下面贴一些自己做过的题目和总结一下比较有用的函数。Problem 1. Times

2013-08-20 19:10:53 3497 2

原创 2011ACM福州网络预选赛B题 HDU4062 Abalone

感谢会长君的指导...现在格式应该正常了...题目大意:给出一种叫做“大王鲍”的桌游,给出游戏规则和双方起始的位置,问先走一方能否获胜...如果不能,问在先走一方走后,后手一方有无必胜策略。如卓锋君所言...是一道神模拟题...把规则全都写对了就好...判断白

2011-10-11 00:18:57 1632

原创 NWERC2010 NKOJ2178 Stock Prices

因为题目数据较小,所以可以直接模拟。每读入一个命令所要进行的操作:如果是buy,则该种价格的买入数+ni,将该种价格加入到买入价格的集合中。如果是sell,则该种价格的卖出数+mi,将该种价格加入到卖出价格的集合中。 然后进行销售的操作:比较最低的卖出价格

2011-10-09 18:55:34 494

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除