CDN加速镜像 | 设为首页 | 加入收藏夹
当前位置: 首页 资源下载 源码下载 Windows编程 其他小程序

文件名称:Statistics

  • 所属分类:
  • 标签属性:
  • 上传时间:
    2013-11-10
  • 文件大小:
    13.46kb
  • 已下载:
    0次
  • 提 供 者:
  • 相关连接:
  • 下载说明:
    别用迅雷下载,失败请重下,重下不扣分!

介绍说明--下载内容来自于网络,使用问题请自行百度

统计逆序对,设a[0…n-1]是一个包含n个数的数组,若在i<j的情况下,有a[i]>a[j],则称(i, j)为a数组的一个逆序对(inversion)。

比如 <2,3,8,6,1> 有5个逆序对。

请考虑一个最坏情况O(nlogn)的算法确定n个元素的逆序对数目。

注意此题请勿用O(n^2)的简单枚举去实现。



并思考如下问题:

(1)怎样的数组含有最多的逆序对?最多的又是多少个呢?

(2)插入排序的运行时间和数组中逆序对的个数有关系吗?什么关系?-Statistical reverse pair, set a [0 ... n-1] is an array that contains the number n, if the i <j的情况下,有a[i]> a [j], called (i, j) is a array of a reverse pair (inversion). Such as < 2,3,8,6,1> has 5 reverse pairs. Consider a worst-case O (nlogn) algorithm to determine the n number of elements on the reverse. Note that this problem Do not use O (n ^ 2) to achieve a simple enumeration. And consider the following questions: (1) how the array contains the most reverse of its? Most is how many do? (2) the running time of insertion sort an array in reverse order and the number on the relationship you have? What is the relationship?
(系统自动生成,下载前可以参看下载内容)

下载文件列表

统计逆序对/tongjinixudui/bin/Debug/tongjinixudui.exe
统计逆序对/tongjinixudui/main.c
统计逆序对/tongjinixudui/obj/Debug/main.o
统计逆序对/tongjinixudui/tongjinixudui.cbp
统计逆序对/tongjinixudui/tongjinixudui.depend
统计逆序对/tongjinixudui/tongjinixudui.layout
统计逆序对/tongjinixudui/bin/Debug
统计逆序对/tongjinixudui/obj/Debug
统计逆序对/tongjinixudui/bin
统计逆序对/tongjinixudui/obj
统计逆序对/tongjinixudui
统计逆序对

相关说明

  • 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
  • 搜珍网是交换下载平台,只提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度。更多...
  • 本站已设置防盗链,请勿用迅雷、QQ旋风等下载软件下载资源,下载后用WinRAR最新版进行解压.
  • 如果您发现内容无法下载,请稍后再次尝试;或换浏览器;或者到消费记录里找到下载记录反馈给我们.
  • 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
  • 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.

相关评论

暂无评论内容.

发表评论

*快速评论: 推荐 一般 有密码 和说明不符 不是源码或资料 文件不全 不能解压 纯粹是垃圾
*内  容:
*验 证 码:
搜珍网 www.dssz.com