现象 m1=[]for i in xrange(n):m1[i]=1 报错:IndexError: list assignment index out of range 分析 空数组不能直接指定位置 解决方法1 m1.append(1) 解决方法2 先生成一个定长的list: m1=[0]*len( ...
                            
                            
                                分类:
其他好文   时间:
2018-10-14 11:23:48   
                                阅读次数:
178
                             
                    
                        
                            
                            
                                    http://codeforces.com/contest/1065/problem/D 我个傻 x 以为对角线移动就是 $(x,y) \rightarrow (x+d,y+d)$。。。 问题 $N$ 行 $N$ 列的国际象棋的棋盘上有一些数字,你要从 $1$ 的位置开始,先移动到 $2$ 的位置, ...
                            
                            
                                分类:
其他好文   时间:
2018-10-12 14:07:00   
                                阅读次数:
208
                             
                    
                        
                            
                            
                                    Description The rotation game uses a # shaped board, which can hold 24 pieces of square blocks (see Fig.1). The blocks are marked with symbols 1, 2 an ...
                            
                            
                                分类:
其他好文   时间:
2018-10-11 18:44:44   
                                阅读次数:
153
                             
                    
                        
                            
                            
                                    数据结构与算法 算法 数据结构与算法分析 编程珠玑 剑指 Offer 操作系统 现代操作系统 深入理解计算机系统 鸟哥的 Linux 私房菜 Unix 环境高级编程 Unix/Linux 编程实践教程 Operating Systems: Three Easy Pieces (OSTEP) 计算机网 ...
                            
                            
                                分类:
其他好文   时间:
2018-10-10 14:34:40   
                                阅读次数:
167
                             
                    
                        
                            
                            
                                my team solve the problem in the contest with similar ideathis is a more deep analysis The main idea is that if some comparator can be defined so that ...
                            
                            
                                分类:
其他好文   时间:
2018-10-04 17:23:36   
                                阅读次数:
150
                             
                    
                        
                            
                            
                                    今天发现一个报错,卡了好几个点,后来发现原因后,脸上三条黑线,尴尬啊!!! 报错:SyntaxError: 'break' outside loopIndexError: list assignment index out of range 上源码: def func(n,target_str):  ...
                            
                            
                                分类:
编程语言   时间:
2018-10-04 09:36:44   
                                阅读次数:
389
                             
                    
                        
                            
                            
                                COMP 3023代写、代写COMP 3023、代做 C++ - Assignment、 代编码C++ - AssignmentRevision 1COMP 3023 Software Development with C++ - Assignment SP5 2018 Page 1 of 22Sc ...
                            
                            
                                分类:
编程语言   时间:
2018-09-22 21:21:04   
                                阅读次数:
145
                             
                    
                        
                            
                            
                                题目:Programming Assignment 4: 8 Puzzle 1. 问题翻译 这回读题读的头大~~(英语差吃亏了)~~,我就先按照自己的理解写下题目的翻译,再写重述性质的内容。 使用A*算法编写一个程序解决各种类型的数字推盘游戏。 问题。数字推盘游戏是Noyes Palmer Chap ...
                            
                            
                                分类:
其他好文   时间:
2018-09-22 19:58:21   
                                阅读次数:
157
                             
                    
                        
                            
                            
                                链接: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=1154 题意: 有一块椭圆形的地。在边界上选n(0≤n<2^31)个点并两两连接得到n(n-1)/ ...
                            
                            
                                分类:
其他好文   时间:
2018-09-12 01:20:49   
                                阅读次数:
209
                             
                    
                        
                            
                            
                                    条款05:了解C++默默编写并调用哪些函数 直入正题:4个函数。 1. default构造函数。 2. copy构造函数。 3. copy assignment操作符。(operator=) 4. 析构函数。 特点: 1. 它们都是public且inline的。 2. 它们只有在被需要(被调用)时才 ...
                            
                            
                                分类:
其他好文   时间:
2018-09-11 16:16:50   
                                阅读次数:
102