- 博客(7)
- 收藏
- 关注
原创 remove2
Error_code List::remove(int position,List.entry &x) { if(count==0) return underflow; if(position=count) return range_enor; Node *new_node,*previous,*followig; if(position>0) { previous=set_po
2013-09-26 12:27:21
629
转载 remove
Error_code List::remove(int position,List.entry &x) { if(count==0) return underflow; if(position=count) return range_enor; x=entry[position]; for(int i=0;i entry[i]=entry[i+1]; count--; retu
2013-09-25 18:50:50
459
转载 3.3 E7
#include using namespace std; const int maxqueue = 10; class Queue{ public: Queue( ); bool empty( ) const; Error_code serve( ); Error_code append(const Q
2013-09-05 19:03:03
523
原创 do_command
bool do_command(char c,Extended_queue &test_queue) { bool continue_input=ture; Queue_entry x; switch(c){ case'r': if(test queue.retrieve(x)==underflow) cout else cout break; case'q'
2013-09-05 18:05:03
872
原创 2.1 E4
(1)当n=3时,有 1,2,3 2,1,3 2,3,1 3,1,2 3,2,1 共 5 种组合。 (2)当n=4时,有 1,2,3,4 2,1,3,4 2,3,1,4 2,3,4,1 3,1,2,4 3,2,1,4 3,2,4,1 3,4,1,2 3,4,2,1 4,1,2,3 4,2,1
2013-08-28 21:59:50
471
原创 2.2 栈的实现
Error_code copy_stack(Stack &dest,Stack &source) { int i=0; Error_code outcome=success; Stack temp; Stack_entry item; while(count==0) outcome=false; else { source.top(item);
2013-08-28 21:53:05
524
1
翻译 数据结构与程序设计——C++语言描述(Data Structures & Program Design in C++) by Robert L.Kruse & Alexander J.Ryba
第1章程序设计原理 率章首先慨述良好程序设计的重要原理,特别是它们在大型项目中的应用;然后介绍用 于发现有救算法的方法,如面向对象的设计和白顶向下的设计。在此过程中,我们提出将在 后继章节中论述的程序设计和数据存储方法方面的问题,并通过使用c'+编写程序,复习一 下这门语言的一些基本特性。 1 1简介 编写大型计算机程序的最大困难不在于确定此程序的目标是什么,也不在于找出达到
2013-08-23 22:18:53
3697
1
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅