搜索资源列表
span_forest
- Computes estimates for the number of forests of a graph, input as a 0-1 incidence matrix. Notes: Compile in C++, \"g++ -o span_forest span_forest.c\". The program does not demand that the matrix is symmetric with 0 diagonal, but uses only the upper t
Fast_Joseph
- 时间复杂度为O(nlogn)的Joseph排列问题的计算程序。程序的运行时间与m无关。在一分钟之内可以计算n=10^6,m任意的Joseph排列问题.-time complexity of O (nlogn) Joseph problems with the program. Procedures for the running time has nothing to do with the m. In a minute can be calculated n = 10 ^ 6, m arbit
LISS_FAST
- 时间复杂度为O(nlogn)的最长单调递增子序列问题的计算程序。不是动态规划算法。在一分钟之内可以计算n=10^6个元素的递增子序列。-time complexity of O (nlogn) of the longest-monotonically increasing sequence of the program. Is not dynamic programming algorithm. In a minute can be calculated n = 10 ^ 6 elements
distsort
- 该程序是分布计数排序,它是我所见过的各种排序方法中最快的,它的时间复杂度为O(n),但是这种排序适用于已知待排序列的上下限,并且如果上限与下限的差值比较大的话,空间消耗也比较大.-distribution of the program is counting sequencing, it is I have seen the fastest sorting methods, it's time complexity of O (n), but this sort known to be
polynomial
- 对已知的多项式p(x)利用用线性表的数据结构进行加法,乘法,微商运算 加法的时间复杂度为O(n+m) 乘法的时间复杂度为O(nm) 微分的时间复杂度为O(n) 排序的平均时间复杂度为O(nlogn) 程序优点:通过顺序表和链表结合使用,使乘法合并同类项的时间复杂度降为O(1),乘法本身的时间复杂度也达到下界。 程序提供了有好的界面,并且有较好的容错性,输入输出人性化,符合人的习惯。 用快速排序代替了插入排序,使本程序能应对较大的数据。 程序缺点:系数和指数有范围限
Exercise8_22
- 写一个程序来创建一个Exercise8_22.txt 文件,随机的100个整数,从文件中读出这些数,并且排序。-Write a program to create a file named Exercise8_22.txt if it does not exist.Wite one hundred integers created radomly into the file using text I/O .Integer are separated by speces in the file.
singlelist
- 单链表的实现学习编程,仅仅实现了部分函数的功能,主函数没有任何意义-源语言: 中文 允许输入拉丁字符的拼音请键入文字或网站地址,或者上传文档。 取消 Dān liànbiǎo de shíxiàn xuéxí biānchéng, jǐnjǐn shíxiànle bùfèn hán shǔ de gōngnéng, zhǔ hánshù méiyǒu rènhé yìyì将中文译成英语 英语中文(简体)日语Learning program to achieve a single
SeqList
- 针对带附加头结点的单链表,试编写下列函数。 (1)定位函数Locate:在单链表中寻找第i个结点。若找到,则函数返回第i个结点的地址;若找不到,则函数返回NULL。 (2)求最大值函数max:通过一趟遍历在单链表中确定值最大的结点。 (3)统计函数number:统计单链表中具有给定值x的所有元素。 (4)建立函数create:根据一维数组a[n]建立一个单链表,使单链表中各元素的次序与a[n]中各元素的次序相同,要求该程序的时间复杂性为O(n)。 -Singly linked
Fortran2
- 这是一个采用平面四边形八节点等参单元的平面有限元分析程序。 PROGRAM PLANEFEM IMPLICIT REAL*8(A-H,O-Z) CHARACTER*80 LINECHAR,NEWLINECHAR COMMON A(30000),L(4000) COMMON /SOL/NPOIN,NELEM,NTYPE,NMATS OPEN(5,FILE= FEMDATA ,STATUS= OLD ) OPEN(6,FILE= FEMOUT ,STATU
6226754PLANEFEM
- PROGRAM PLANEFEM IMPLICIT REAL*8(A-H,O-Z) CHARACTER*80 LINECHAR,NEWLINECHAR COMMON A(30000),L(4000) COMMON /SOL/NPOIN,NELEM,NTYPE,NMATS OPEN(5,FILE= FEMDATA ,STATUS= OLD ) OPEN(6,FILE= FEMOUT ,STATUS= UNKNOWN ) C 以下进行的是从数据文件FEMDAT
hufferman
- 用下表给出的字符集和频度的实际统计数据建立哈夫曼树,并实现以下报文的编码和译码:“THIS PROGRAM IS MY FAVORITE”字符 A B C D E F G H I J K L M 频度 64 13 22 32 103 21 15 47 57 1 5 32 20 字符 N O P Q R S T U V W X Y Z 频度 57 63 15 1 48 51 80 23 8 18 1 16 1-The actual statistics of the character set a
4
- 本题关于排序与细节处理,故选择int数组作为数据结构。 算法思想如下:对于输入的数据,根据其后的‘+’‘-’,用a,b的数组分别记录染病和正常的动物的高度。然后分别将a,b两数组排序。对于其后的m组询问,分别求出要杀中的动物数量x和最多误杀的动物数量y,分别询问a,b数组的倒数x,y位置的元素,稍作处理,分别作为最高高度和最低高度输出(若不和逻辑,输出-1)。程序结束。 复杂度:本题的运算时间主要用于排序(快排),故复杂度为O(nlogn)。空间复杂度是 O(n)。 -This
MergeMutiply
- 用这个程序对你想要排序的数组进行排序,这个程序采用的是合并排序法,算法效率是O(nlogn)(Use this program to sort the array you want to order. This program uses the merge sort method, and the algorithm efficiency is O (nlogn))