文件名称:1
-
所属分类:
- 标签属性:
- 上传时间:2015-12-28
-
文件大小:4.55kb
-
已下载:3次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
以正整数n,i,k作为输入,其中n,i,k>0,且i<n。假定数1,2,…,n是环形排列的。试编写一个程序,从数i开始,按顺时针方向以k为步长打印数,当打印某个数时,应从环中删去该数,这样的过程一直进行到环空为止。例如,当n=10,i=1,k=3时,得到的输出序列是3,6,9,2,7,1,8,5,10,4。-In a positive integer n, i, k as an input, wherein n, i, k> 0, and i <n. Assuming that the number 1,2, ..., n is an annular array. Try to write a program, starting number i, k clockwise direction increments the number of prints, when printing a number, this number should ring deleted, this process has been carried out to the ring empty. For example, when n = 10, i = 1, k = 3, the output sequence is obtained 3,6,9,2,7,1,8,5,10,4.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
1/myjava/Josephus.java
1/myjava/LList.java
1/myjava/myjava/Josephus.class
1/myjava/myjava/LList.class
1/myjava/myjava/SeqList.class
1/myjava/myjava
1/myjava/SeqList.java
1/myjava
1
1/myjava/LList.java
1/myjava/myjava/Josephus.class
1/myjava/myjava/LList.class
1/myjava/myjava/SeqList.class
1/myjava/myjava
1/myjava/SeqList.java
1/myjava
1
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.