随笔分类 - ACM
exercise for algorithms
摘要:poj 2676DescriptionSudoku is a very simple task. A square table with 9 rows and 9 columns is divided to 9 smaller squares 3x3 as shown on the Figure. In some of the cells are written decimal digits from 1 to 9. The other cells are empty. The goal is to fill the empty cells with decimal digits from 1
阅读全文
摘要:poj 2488 knight's journeyBackgroundThe knight is getting bored of seeing the same black and white squares again and again and has decided to make a journeyaround the world. Whenever a knight moves, it is two squares in one direction and one square perpendicular to this. The world of a knight is the
阅读全文
摘要:poj 2251InputThe input consists of a number of dungeons. Each dungeon description starts with a line containing three integers L, R and C (all limited to 30 in size).L is the number of levels making up the dungeon.R and C are the number of rows and columns making up the plan of each level.Then there
阅读全文
摘要:what makes me amused joyful is I use emacs coding this algorithm..:)although i am not proficient in it at all.besides, today I installed aqumacs in place of the built-in emacs of Mac. thereby(thus) reviewed the bash command and the profile .bash_profile----------------------------------------------
阅读全文
摘要:poj 1125 Stockbroker GrapevineInputYour program will input data for different sets of stockbrokers. Each set starts with a line with the number of stockbrokers. Following this is a line for each stockbroker which contains the number of people who they have contact with, who these people are, and t
阅读全文
摘要:easy quiz
阅读全文
摘要:最简单的递归问题,费波纳妾问题递归的关键,找出边界条件; 要考虑包含所有可能情况第二个简单问题: 二叉树:
阅读全文
摘要:problem 1:生理周期simple enumerate-------------------------------------------------------------------------------------------------problem 2:称硬币model with several variables以字符串数组存储称量的结果。每次称量时,天平左右最多有6 枚硬币...
阅读全文
摘要:数据结构: 二叉树运用递归的方法构造二叉树,二叉树的根节点root代表一棵二叉树。递归方法理解的还不够深刻。下一次从递归开始训练
阅读全文
摘要:fuck。。。。打错一个变量名害我在这题上用了n长时间,我就搞不懂了。。怎么debug都不会么????!!!!!tmd。。。好好分析这种题目。。然后做一篇关于debug的总结。holy shit!!!杯具啊。。。我真是差好多好多。。就这现在这鸟样就别说自己是学计算机的了。。
阅读全文
摘要:0 0 0 0 0 0 0 0 0 p 0 0 p P&p p 0 0 p? 0 0 0 0 0 !the value of press[][] is up to Puzzle[][] previous row and press[][] previous row !use 8*8 matrix to simplify the formula so that we do no...
阅读全文
摘要:/**find a formula which satisfy a^3=b^3+c^3+d^3*/·关键在于去重减少预算量方法:把要用到的立方都存储起来,防止重复计算。·排除显而易见的不可能的情况,如当 a^3<b^3+c^3+d^3 即 break·头文件math.h
阅读全文
摘要:/*some coins weigh 3 times can identify which one is conterfeitcounterfeit. */ #include #include using namespace std; /**store the input*/ char left1[3][7]; //用数组的时候记得给数组确定范围 char right1[3][7]...
阅读全文
摘要:/**give one day that 3 physiological peak occur simultaneously*/代码总结:重新开始做acm题,发现编程已经相当生疏。解决了dev-c++ 不能debug的问题
阅读全文
posted @ 2010-04-15 11:24
love && peace
浙公网安备 33010602011771号