上一页 1 ··· 26 27 28 29 30 31 32 33 34 ··· 50 下一页
摘要: 小米2在Eclipse 调试,要注意下列步骤。1、连接线,打开设置:USB线连接小米2,在设置-->开发者选项->USB 调是打开。如果这一步,就业在Eclipse中真机调试,下面的步骤不要看了。如果不行,请继续;2、检查驱动:检查小米2驱动是否安装成功,如果win7下,安装驱动 稍稍和WinXP不... 阅读全文
posted @ 2015-10-13 09:28 gongpixin 阅读(254) 评论(0) 推荐(0) 编辑
摘要: 题意: 思路: 阅读全文
posted @ 2015-10-05 11:33 gongpixin 阅读(208) 评论(0) 推荐(0) 编辑
摘要: 题意:经典八数码问题思路:双向bfsps:还有a*算法(还不会)等解法。代码:#include#include#include#includeusing namespace std;#define MAXN 362885//最多组合个数:9!=362880int dir[4]={-3,3,-1,1}... 阅读全文
posted @ 2015-09-21 11:00 gongpixin 阅读(514) 评论(0) 推荐(0) 编辑
摘要: 一:知识点 数据结构: 1,单,双链表及循环链表 2,树的表示与存储,二叉树(概念,遍历)二叉树的 应用(二叉排序树,判定树,博弈树,解答树等) 3,文件操作(从文本文件中读入数据并输出到文本文 件中) 4,图(基本概念,存储结构,图的运算) 数学知识 1,离散数学知识的应用(如排列组合、简单的图论 阅读全文
posted @ 2015-09-21 10:52 gongpixin 阅读(4064) 评论(0) 推荐(2) 编辑
摘要: 1.康托展开的解释 康托展开就是一种特殊的哈希函数 把一个整数X展开成如下形式: X=a[n]*n!+a[n-1]*(n-1)!+...+a[2]*2!+a[1]*1! 其中,a为整数,并且0<=a<i,i=1,2,..,n {1,2,3,4,...,n}表示1,2,3,...,n的排列如 {1,2 阅读全文
posted @ 2015-09-21 10:04 gongpixin 阅读(286) 评论(0) 推荐(0) 编辑
摘要: 题意:模拟文本操作 思路:模拟 #include<iostream> #include<stdio.h> #include<string.h> using namespace std; #define MAXN 10005 int M; char cmd[MAXN]; char str1[MAXN] 阅读全文
posted @ 2015-09-20 20:29 gongpixin 阅读(255) 评论(0) 推荐(0) 编辑
摘要: 看这个斐波那契数列,错误来源:wdy#include#includeusing namespace std;int main(){ int i,m; int a[20]; m=0; //cout<<"m = "<<m<<endl; a[0]=a[1]=1; for... 阅读全文
posted @ 2015-09-09 21:01 gongpixin 阅读(220) 评论(0) 推荐(0) 编辑
摘要: 题意:判断最小生成树是否唯一。 思路:求出次小生成树,如果与最小生成树相等,则不唯一。 prim: #include<iostream> #include<stdio.h> #include<string.h> using namespace std; /* 求最小生成树时,用数组Max[i][j] 阅读全文
posted @ 2015-09-05 16:40 gongpixin 阅读(219) 评论(0) 推荐(0) 编辑
摘要: 题意:裸最小生成树,主要是要按照字典序。 思路:模板 prim: #include<iostream> #include<stdio.h> #include<string.h> #include<algorithm> using namespace std; #define INF 0x7fffff 阅读全文
posted @ 2015-09-05 14:18 gongpixin 阅读(373) 评论(0) 推荐(0) 编辑
摘要: 题意:n个点修路,要求总长度最小,但是有两个点p、q必须相连 思路:完全图,prim算法的效率取决于节点数,适用于稠密图。用prim求解。 p、q间距离设为0即可,最后输出时加上p、q间的距离 prim算法: #include<iostream> #include<stdio.h> #include 阅读全文
posted @ 2015-09-04 20:28 gongpixin 阅读(232) 评论(0) 推荐(0) 编辑
上一页 1 ··· 26 27 28 29 30 31 32 33 34 ··· 50 下一页