文件名称:Josephus-problem
介绍说明--下载内容来自于网络,使用问题请自行百度
(2)利用循环链表实现约瑟夫问题的求解。 约瑟夫问题如下:已知n个人(n≥1)围坐一圆桌周围,从1开始顺序编号。从序号为1的人开始报数,顺时针数到m的那个人出列。他的下一个人又从1开始报数,数到m的那个人又出列。依次规则重复下去,直到所有人全部出列。请问最后一个出列的人的编号-(2) the use of circular linked list to achieve problem solving Joseph. Joseph problem as follows: Given n individual (n≥1) sitting around a round table, in order a start number. From the number of people began to count off 1, clockwise number to m the man out of the column. His next person and 1 Countin, count to m the man was out of the column. Turn rule is repeated until everyone all the columns. Will the last one out of the column number of people
(系统自动生成,下载前可以参看下载内容)
下载文件列表
Josephus problem.docx
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.