当前位置: 首页 > news >正文

dz网站如何做301比较漂亮的营销型网站

dz网站如何做301,比较漂亮的营销型网站,商标交易,wordpress 功能小工具栏1 均匀成本搜索 均匀成本搜索是迪杰斯特拉算法的变体。这里#xff0c;我们不是将所有顶点插入到一个优先级队列中#xff0c;而是只插入源#xff0c;然后在需要时一个接一个地插入。在每一步中#xff0c;我们检查项目是否已经在优先级队列中(使用访问数组)。如果是我们不是将所有顶点插入到一个优先级队列中而是只插入源然后在需要时一个接一个地插入。在每一步中我们检查项目是否已经在优先级队列中(使用访问数组)。如果是我们执行减少键否则我们插入它。 这个 Dijkstra 的变体对于无限图和那些太大而无法在内存中表示的图很有用。均匀成本搜索主要用于人工智能。 均匀成本搜索类似于迪杰斯特拉算法。在该算法中从起始状态开始我们将访问相邻的状态并将选择代价最小的状态然后我们将从所有未访问的状态和访问状态的相邻状态中选择下一个代价最小的状态这样我们将尝试到达目标状态(注意我们不会继续通过目标状态的路径)即使我们到达目标状态我们也将继续搜索其他可能的路径(如果有多个目标)。我们将保持一个优先级队列该队列将给出来自被访问状态的所有相邻状态中成本最低的下一个状态。 2 均匀成本搜索源程序 using System; using System.Collections; using System.Collections.Generic; namespace Legalsoft.Truffer.Algorithm {     public static class LargeGraph     {         private static ListListint graph new ListListint(); // Tuple 多元组数据         private static DictionaryTupleint, int, int cost new DictionaryTupleint, int, int(); public static Listint Uniform_Cost_Search(Listint goal, int start)         {             Listint answer new Listint(); ListTupleint, int queue new ListTupleint, int(); for (int i 0; i goal.Count; i)             {                 answer.Add(int.MaxValue);             } queue.Add(new Tupleint, int(0, start)); Dictionaryint, int visited new Dictionaryint, int(); int count 0; while (queue.Count 0)             {                 Tupleint, int q queue[0];                 Tupleint, int p new Tupleint, int(-q.Item1, q.Item2); queue.RemoveAt(0); if (goal.Contains(p.Item2))                 {                     int index goal.IndexOf(p.Item2); if (answer[index] int.MaxValue)                     {                         count;                     }                     if (answer[index] p.Item1)                     {                         answer[index] p.Item1;                     }                     queue.RemoveAt(0); if (count goal.Count)                     {                         return answer;                     }                 }                 if (!visited.ContainsKey(p.Item2))                 {                     for (int i 0; i graph[p.Item2].Count; i)                     {                         queue.Add(new Tupleint, int((p.Item1 (cost.ContainsKey(new Tupleint, int(p.Item2, graph[p.Item2][i])) ? cost[new Tupleint, int(p.Item2, graph[p.Item2][i])] : 0)) * -1,                         graph[p.Item2][i]));                     }                 }                 visited[p.Item2] 1;             } return answer;         }     } } 3 代码格式 using System; using System.Collections; using System.Collections.Generic;namespace Legalsoft.Truffer.Algorithm {public static class LargeGraph{private static ListListint graph new ListListint();// Tuple 多元组数据private static DictionaryTupleint, int, int cost new DictionaryTupleint, int, int();public static Listint Uniform_Cost_Search(Listint goal, int start){Listint answer new Listint();ListTupleint, int queue new ListTupleint, int();for (int i 0; i goal.Count; i){answer.Add(int.MaxValue);}queue.Add(new Tupleint, int(0, start));Dictionaryint, int visited new Dictionaryint, int();int count 0;while (queue.Count 0){Tupleint, int q queue[0];Tupleint, int p new Tupleint, int(-q.Item1, q.Item2);queue.RemoveAt(0);if (goal.Contains(p.Item2)){int index goal.IndexOf(p.Item2);if (answer[index] int.MaxValue){count;}if (answer[index] p.Item1){answer[index] p.Item1;}queue.RemoveAt(0);if (count goal.Count){return answer;}}if (!visited.ContainsKey(p.Item2)){for (int i 0; i graph[p.Item2].Count; i){queue.Add(new Tupleint, int((p.Item1 (cost.ContainsKey(new Tupleint, int(p.Item2, graph[p.Item2][i])) ? cost[new Tupleint, int(p.Item2, graph[p.Item2][i])] : 0)) * -1,graph[p.Item2][i]));}}visited[p.Item2] 1;}return answer;}} }
http://www.pierceye.com/news/189961/

相关文章:

  • 电子商务网站的建设与维护方法h5第三方收款平台
  • 网站建设所需人力设计广告网站
  • php网站发送邮件动态倒计时网站模板
  • 温州建设网站制作wordpress调用文章简介
  • 大庆市建设局网站刘东科技公司做网站
  • 山东助企网站建设宁波百度关键词推广
  • 宜昌市夷陵区建设局网站培训推广 seo
  • 怎样做安居客网站用幽默的语言来形容网站开发
  • 宜昌网站建设选择宜昌慧享互动手机怎么防止网站跳转
  • 本地的上海网站建设公司汽车租赁网站设计
  • 在哪下载免费的英文版网站模板建站 网站程序有哪些
  • 网页前端做购物网站的实训报告网络营销推广是做什么的
  • 广东专业网站建设效果wordpress搜索框插件
  • 茂名建站模板搭建岳阳优化营商环境
  • shopify网站建设郑州机械网站制作
  • 郑州正规公司网站建设服务国内专业建站平台
  • 做财经直播网站php网站做安卓客户端
  • 视频直播网站开发运营步骤十大免费erp软件
  • 域名备案和网站备案有什么不同wap 网站
  • 没备案的网站百度收录博客营销
  • 网站开发新技术wordpress 搜索词调用
  • 凡科手机建站教程wordpress 搜索引擎
  • asp企业网站源码下载免费ppt模板公众号
  • 西斗门的网站建设短网址生成器有哪些
  • 一站式织梦网站模板工信部备案查询网官网
  • 网站导航做外链桂林seo
  • 青岛网站建设q479185700棒软件开发者是指
  • 福永公司网站建设空间网站链接怎么做
  • 百度的企业网站谷歌浏览器下载安卓版
  • 网站建设总体情况网站设计宁波