登录
首页 » Visual C++ » pinfanfangwen

pinfanfangwen

于 2015-01-15 发布 文件大小:1KB
0 209
下载积分: 1 下载次数: 11

代码说明:

  设有一头指针为L的带有表头结点的非循环双向链表,其每个结点中除有prev(前驱指针),data(数据)和next(后继指针)域外,还有一个访问频度域freq。在链表被起用前,其值均初始化为零。每当在链表中进行一次Locate(L,x)运算时,令元素值为x的结点中freq域的值增1,并使此链表中结点保持按访问频度非增(递减)的顺序排列,同时最近访问的结点排在频度相同的结点的最后,以便使频繁访问的结点总是靠近表头。试编写符合上述要求的Locate(L,x)运算的算法,该运算为函数过程,返回找到结点的地址,类型为指针型。(Has a head pointer is non-circular doubly linked list L with a header node, each node in addition to prev (precursor pointer), data (data) and next (successor pointers) outside, there is an access frequency degree domain freq. Before the list was hired, their values are initialized to zero. Whenever carried out in the list once Locate (L, x) when the operation, so that the element node x is the value in freq domain by one, and keep this list in the node-access frequency of non-increasing (decreasing) the order, while a recent visit to the nodes in the same row of the frequency of the last node, so that the nodes are frequently accessed tables are always near the head. Locate (L, x) algorithm is prepared in accordance with the above requirements of the test operation, the operation as a function of the process, return to find the address of the node of type pointer.)

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • jiaotongzixun
    数据结构的课程设计,做的是一个交通查询,主要用到图的算法,和大家共享,欢迎指正!(Data structure curriculum design, do a query traffic, mainly used graph algorithms, and share, please correct me!)
    2013-10-28 18:49:11下载
    积分:1
  • strcon
    对于给定的n个字符串,请找出一种最佳的连接方式,使得采用该连接方式得到的字符串在所有连接的结果中,字典序最小(For a given n-string, find an optimal connection, making use of the connection string to get the results in all connections, the lexicographic minimum)
    2011-09-02 16:52:40下载
    积分:1
  • Dijlstra
    Dijlstra算法 对任意图,选择合适的数据结构表示图,在此基础上实现求解最短路径的Dijkstra算法(Dijlstra algorithm to arbitrary map, select the appropriate data structures that map, on this basis to achieve solution of the Dijkstra shortest path algorithm)
    2009-01-11 19:03:11下载
    积分:1
  • 123
    校园导航系统 1) 校园景点介:绍介相关景点的有关详细信息。 2) 最佳路线查询:查询校园中任意两点之间所有路线,并提供两点间最短的简单路径。 3) 关节点查询:提供校园图的关节点查询。 4) 多景点最佳路线查询:提供多个景点的最佳线路查询,即求途径这个景点的最佳路径。 (Campus Navigation System 1) campus attractions Introduction: Shao Jie-related attractions for more information. 2) The best route query: Query on campus all the routes between any two points, and provides a simple shortest path between two points. 3) joint points: the key points to provide the campus map queries. 4) The best route queries more attractions: multiple sites to provide the best route queries, that is seeking ways to this spot the best path.)
    2011-08-25 08:56:05下载
    积分:1
  • exp2-1
    数据结构(第四版)第二章上机实验题源程序答案详解(Data structure (fourth edition) chapter on lab answer questions Detailed source)
    2014-12-31 09:14:51下载
    积分:1
  • classical-algorithm-VCPP
    常用的算法经典代码,包括快速排序,冒泡排序等各种排序方法,还有二叉树的前序、中序和后序遍历等(The classic algorithm code, including quick sort and bubble sort sorting methods, as well as the preamble of the binary tree, inorder and postorder traversal, etc.)
    2013-01-15 11:15:10下载
    积分:1
  • LinearList
    单链表程序 可执行单链表的基本功能 创建 删除 查找 存取 等等(Basic functions to create a single linked list program executable single linked list delete find access)
    2012-10-31 17:15:54下载
    积分:1
  • ecs
    说明:  二叉树的演示程序。实现了二叉树和哈弗曼树(Binary tree demo program. Implements a binary tree and the tree Hafu Man)
    2011-03-26 11:59:58下载
    积分:1
  • jiajianfa
    长整数四则运算,利用双向循环链表实现长整数的存储,每个结点含一个整形变量。 (Long integer arithmetic, the use of two-way circular linked list to achieve long integer storage, each node contains an integer variable.)
    2014-05-29 14:41:51下载
    积分:1
  • 001
    二叉树的中序遍历,先序遍历以及后序遍历的算法(Binary tree in preorder traversal, preorder traversal and postorder traversal algorithm)
    2012-06-03 23:26:44下载
    积分:1
  • 696518资源总数
  • 106222会员总数
  • 14今日下载