文件名称:VCPPinsort
-
所属分类:
- 标签属性:
- 上传时间:2012-11-16
-
文件大小:3.69kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
1. 采用插入排序的方法,输入10个整数按升序排序后输出。要求编写一个通用的插入排序函数InsertSort()。它带有三个参数,第一个参数是含有n个元素的数组,这n个元素已按升序排序;第二个参数给出当前数组中元素的个数;第三个参数是要插入的整数。该函数的功能是将一个整数插入到数组中,然后进行排序。另外还需要一个用于输出数组元素的函数Print(),要求每一行输出5个元素。-A. Insertion sort, the output of input 10 integers sorted in ascending order. Prepared at the request of a generic function InsertSort insertion sort (). With three parameters, the first parameter contains an array of n elements, n elements are sorted in ascending order second parameter gives the number of elements in the current array The third parameter is the integer to be inserted . The functionality of the function is inserted into an integer array, then sort. Also need an output array elements function the Print (), each line of output of five elements.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
VC++insort.doc
1999-2046 搜珍网 All Rights Reserved.
本站作为网络服务提供者,仅为网络服务对象提供信息存储空间,仅对用户上载内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。
