05 2021 档案

摘要:#if 0#include<iostream>#include<queue>#include<vector>using namespace std; class Travling { friend void TSP(int**, int);private: int n; int** dis; int 阅读全文
posted @ 2021-05-17 23:01 梦醒如赦 阅读(108) 评论(0) 推荐(0) 编辑
摘要:#if 1#include<iostream>#include<queue>#include<vector>using namespace std; class Travling { friend void TSP(int**,int);private: int n;//点个数 int** dis; 阅读全文
posted @ 2021-05-17 23:00 梦醒如赦 阅读(69) 评论(0) 推荐(0) 编辑
摘要:#if 1#include<iostream>using namespace std; class Color { friend int mColoring(int, int, int**);private: bool Ok(int k);//检查颜色可用性 void Backtrack(int t 阅读全文
posted @ 2021-05-09 10:41 梦醒如赦 阅读(161) 评论(0) 推荐(0) 编辑
摘要:#include<iostream>#include<algorithm>using namespace std;#define MAX 999; class Flowshop { friend int Flow(int** M, int n, int* bestx);private: void B 阅读全文
posted @ 2021-05-08 18:11 梦醒如赦 阅读(324) 评论(0) 推荐(0) 编辑
摘要:#if 0#include<iostream>using namespace std;struct EdgeType //关于图中边的信息的结构体{ int from, to; int Weight;};struct EdgeGraph //关于整个图中顶点、边的所有信息,需要将前面边的结构体内容导 阅读全文
posted @ 2021-05-08 18:09 梦醒如赦 阅读(60) 评论(0) 推荐(0) 编辑
摘要:#if 0#include<iostream>using namespace std;#define maxint 999 template<class Type> void Prim(int n, Type ** c) {//c[i][j]表示边(i,j)的权值,n是顶点个数 Type *lowc 阅读全文
posted @ 2021-05-08 18:08 梦醒如赦 阅读(120) 评论(0) 推荐(0) 编辑
摘要:#if 1#include<iostream>#include<algorithm>using namespace std;template<class Typew,class Typep>class Knap { friend Typep Knapsack(Typep*, Typew*, Type 阅读全文
posted @ 2021-05-07 22:01 梦醒如赦 阅读(234) 评论(0) 推荐(1) 编辑
摘要:#include<iostream>#include<cmath>using namespace std; class Queen { friend int nQueen(int);private: bool Place(int k); void Backtrack(int t); int n,// 阅读全文
posted @ 2021-05-07 21:26 梦醒如赦 阅读(152) 评论(0) 推荐(0) 编辑
摘要:先画坐标轴 package start;import java.awt.Color;import java.awt.Graphics2D;import java.awt.Graphics;import java.awt.geom.GeneralPath; import javax.swing.*;p 阅读全文
posted @ 2021-05-05 12:55 梦醒如赦 阅读(565) 评论(0) 推荐(0) 编辑
摘要:package start;import java.awt.*;import java.awt.event.*;import javax.swing.*;import java.util.Arrays;import java.util.Set;import java.util.TreeMap; pu 阅读全文
posted @ 2021-05-05 10:25 梦醒如赦 阅读(1156) 评论(0) 推荐(0) 编辑
摘要:#include<iostream>using namespace std; class Loading { friend int MaxLoading(int* w, int c, int n, int* bestx);private: void Backtrack(int i); int n;/ 阅读全文
posted @ 2021-05-03 10:45 梦醒如赦 阅读(217) 评论(0) 推荐(0) 编辑
摘要:【问题描述】使用动态规划算法解凸多边形最优三角剖分问题,具体来说就是,依据递归式,按照顺序求得子问题,使得该三角剖分中诸三角形上权之和为最小。 【输入形式】在屏幕上输入凸多边形顶点个数和顶点坐标。 【输出形式】最优三角剖分后的三角形顶点。 【样例1输入】 7 8 26 0 20 0 10 10 0 阅读全文
posted @ 2021-05-03 10:34 梦醒如赦 阅读(528) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示