文件名称:joseph
介绍说明--下载内容均来自于网络,请自行研究使用
编号为1,2,…,的个人按顺时针方向围坐一圈,每人持有一个密码(正整数)。一开始任选一个正整数作为报数上限值,从第一个人开始按照顺时针方向自1开始顺序报数,报到时停止报数。报的人出列,将他的密码作为新的值,从他在顺时针方向上的一个人开始重新从1报数,如此下去,直至所有人全部出列为止。试设计一个程序求出出列顺序。-Numbered 1,2, ..., individuals sitting around a clockwise direction, each holder of a password (positive integer). One began to choose a positive integer as the number of upper limit reported from the first person since the beginning of a clockwise direction in accordance with the order of one to start off, back off, when to stop. Those who reported a series of his password as a new value, in a clockwise direction from him on the restart from the beginning of a one off, and so on, until all the column until all. Try to design a procedure to derive the column order.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
joseph.C