搜索资源列表
算法(strassen和strassen混合算法)
- strassen算法的扩展,可以计算任何偶数阶矩阵的相乘,一般strassen只能计算2的n次方阶(自己编写,英文注释~)-Strassen expansion algorithm can even order any calculation of matrix multiplication, general Strassen only two terms of the n-th-order (to prepare themselves, English Notes ~)
LimitBin
- 装箱问题:在装箱问题中,有若干个容量为c 的箱子和n 个待装载入箱子中的物品。物品i 需占 用s[i]个单元(0< s[i]≤c)。成功装载是指能把所有物品都装入箱子。最优装载是指使用最 少箱子的成功装载。 例如某运输公司要把包裹装入卡车中,每个包裹都有一定的重量,且每辆卡车也有其载 重限制(假设每辆卡车的载重都一样)。在卡车装载问题中,希望用最少的卡车来装载包裹。 此问题可看作装箱问题。卡车对应于箱子,包裹对应于物品。 解装箱问题的Best Fit 算法: 设
ShortPth
- 图论:最短路径算法实现 Graph.gph GraphBFS.h GraphM.h GraphOpr.h Queue.h sample.gph ShortPth.cpp ShortPth.dsp ShortPth.dsw ShortPth.ncb ShortPth.opt ShortPth.plg-graph theory : the shortest path algorithm Graph.gph GraphBFS.h GraphM.h Gra
guize
- The government of a small but important country has decided that the alphabet needs to be streamlined and reordered. Uppercase letters will be eliminated. They will issue a royal decree in the form of a String of B and A characters. The first charact
qipanfugaiwenti
- 棋盘覆盖问题:在一个2的k次幂乘以2的k次幂个方格组成的棋盘中,恰有一个方格与其他方格不同,称该方格为一特殊方格,且称该棋盘为一特殊棋盘。在棋盘覆盖问题中,用四种不同形态的L型骨牌覆盖给定的特殊棋盘上除特殊方格以外的所有方格。 -chessboard coverage : two in a k-th power of 2 multiplied by the k-th power grid consisting of a chessboard, and a box with the other
CPP1 顺序表的基本操作实现实验
- 一、顺序表的基本操作实现实验 要求:数据元素类型ElemType取整型int。按照顺序存储结构实现如下算法: 1)创建任意整数线性表(即线性表的元素值随机在键盘上输入)的顺序存储结构(即顺序表),长度限定在25之内; 2)打印/显示(遍历)该线性表(依次打印/显示出表中元素值); 3)在顺序表中查找第i个元素,并返回其值; 4)在顺序表第i个元素之前插入一已知元素; 5)在顺序表中删除第i个元素; 6)求顺序表中所有元素值(整数)之和; 二、链表(
数组按从小到大的顺序排序
- 这是一个简单的排序。给你一个有N个值的数组,每个数都小于10000000。然后就将这个数组按从小到大的顺序排序。在输入时,第一行输入一个整数T,T代表一个有多少个数组要排序。然后就有T组数,每组数的第一行就是数组的大小N。紧跟着就有N行数,第N行就是数组的第N个数。每个数组的输出就有N行。,Given you an array with N non-negative integers which are smaller than 10,000,000, you have to sort this
miqumo
- 幂取模的算法,能快速求出a的b次方模c的结果。-Power modulo algorithm can quickly find a b-th mode c results.
training
- 某企业将挑选一批新员工进行培训,遵循以下规则: 将所有员工排成1个圈,从12点位置开始编号为1,逆时钟方向编号到N,第N号员工在第1号的左手边 两位培训官开始选择员工,培训官甲从1号开始逆时钟方向数,数到第k号员工停下;培训官乙从N号开始顺时钟方向数,数到第m号员工停下 被选中的第k号和第m号员工不是同一人,两人同时送往制造培训 被选中的第k号和第m号员工是同一人,将一人送往检测培训 接着继续往下数,培训官甲同样数到k就停止,培训官乙同样数到m就停止,重复上述的选择 输入
LinkList 实现单链表的所有基本操作
- 1、实现单链表的所有基本操作包括表的初始化、第i个元素前插入一个新的元素、删除第i个元素、查找某元素、顺序表的销毁。 2、测试链表所有功能 3、实现循环链表的基本操作,并编写测试程序。 4、实现双向链表的基本操作,并编写测试程序。 5、实现单链表的逆置。 6、判定两个链表是否相交。-A single linked list of all the basic operations, including the initialization of the table,
8
- This program identifies the best poker hand made up of 5 cards from the 7 provided. These cards are - or space separated and look like this: 3S-9D 5S-6D-TH-2S-KC. The first letter of each pair is the value which is one of 2,3,4,5,6,7,8,9,T,J,Q,K, A.
SqList
- 1.实现顺序表的基本操作,包括顺序表的初始化、第i个元素前插入一个新的元素、删除第i个元素、查找某元素、顺序表的销毁。 2.建立并显示含有n个整数的顺序表 3.实现对有序表(非递减)插入一个元素的功能 4.实现两个有序(非递减)表合并生成新的有序表的功能 5.顺序查找顺序表,删除元素e(只删除找到的第一个值为e的元素)。 6.顺序查找顺序表,删除元素e(删除所有值为e的元素)。 -(1) the basic operation of the order of the ta
zerone
- 【题目描述】 Adam 和Eve 被赶出伊甸园后,盖起了四面高墙。高墙上写着n 行01 串。两人无事可做,于是 开始就这些01 串做如下博弈: 1. Adam 进行第1 手,此后双方轮流操作。 2. 第 i 手的操作者,可以且必须在0 和1 之间选择,并相应地抹掉某些串。具体地,若选择 0(1),则抹掉第i 位为0(1)的所有串。长度短于i 的串,也须抹掉。 3. 一方操作之后若将所有串都抹掉了,则判该方失败。 若两人皆明智,则胜负必然确定。不幸的是他俩
BPNet
- 递归算法示例计算,供相互学习之用.他可计算:n的1次方到n的k次方的和.-Example calculation of recursive algorithm, for mutual learning. He Computable: n-th power of 1 to n and the k-th power.
MKTHNUM
- K-th smallest number for a given a range in (logN)^3 per query.
3204
- zoj 3204 Connect them的源码,主要考察最小生成树的Kruskal算法,要注意输出的顺序-the source code of zoj 3204 Connect them , the main study Kruskal minimum spanning tree algorithm, should pay attention to the order of the output
digui
- 本段代码实现的功能是:递归实现x的n次幂-The functionality of the code is: recursion x n-th power
List
- 对链表的一些处理,包括头插法建表,尾插法建表,链表长度运算 ,求链表第i个元素运算 ,按值查找运算,插入结点运算,删除结点运算,逆置链表运算-On the list of some of the processing, including construction of the first interpolation table, end table built interpolation, computing the length of the list, find the i-th elem
TheBoredomDivTwo
- topcoder 698 题目 John and Brus are bored. They have n+m common friends. The first n of them are bored and other m are not. John chooses the j-th (1-based) friend for a talk. If the friend is not bored, he becomes bored after the talk. Brus does the sa
verse K-th problem
- FancyCoder提出了一个叫做“反向第K个问题”的问题。描述也很简单:给定一个数组包含N个整数A [1],A [2],...,A [n]和一些查询的数组,每次查询要求找出符合第K大的数是X的连续子序列的数目。 第一行包含一个整数T(1 <= T <= 5),表示测试用例数。 对于每个测试用例:第一行包含两个整数N和Q(1 <= N <= 2,000,1 <= Q <= 2,000,000),表示阵列中有N个整数,Q次查询。 第二行包含1和N之间的N个