搜索资源列表
xunhuanlianbiao-Josephus
- 用循环链表解Josephus问题。设有n个人围坐在一个圆桌周围,现从第1个人开始报数,数到第m的人出列,然后从出列的下一个人重新开始报数,数到第m的人又出列,…,如此反复直到所有的人全部出列为止。Josephus问题是:对于任意给定的n和m,求出按出列次序得到的n个人员的序列,如n=8,m=4时,输出序列是48521376。-cyclic Chain Solutions Josephus problem. N with the individuals sitting around a round
JOSEPHUS问题
- 这是一个Josephus问题的C++代码,用双向链表实现.有问题题请联系ho1983xx@tom.com (2005-5-22,VC,1KB,下载0次)【向站长举报此文件和某个同类文件可能重复】-This a C++ code about Josephus problem, and use two-way chain form to realize.If you have any problem, please contact ho1983xx@tom.com
Josephus
- Josephus问题:一群小孩围成一圈,任意假定一个数m,从第一个小孩起,顺时针方向数,每数到第m个小孩是,该小孩便离开。小孩不断离开,圈子不断缩小。最后,剩下的一个小孩便是胜利者。究竟胜利的是第几个小孩呢? 提示:用循环链表解答,编写程序link.h实现循环的链表类,由插入与删除等基本操作。 -Josephus problem: a group of kids form a circle, any assumption that a number of m, starting from
Josephus
- java源代码,经典问题,约瑟夫环问题-java source code, the classic problem, the issue of Joseph Central
Josephus
- Josephus 问题描述 数据结构为链表的插入与查询-Josephus Problem Descr iption
josephus
- josephus问题,该问题非常经典,有助于初学者学习-josephus problem, the problem is very classic, will help beginners learn
Josephus
- java的经典example——在java中用链表解决约瑟夫环问题~-solve Josephus problem in java
Josephus
- 线性标的应用——Josephus问题(顺序)线性标的应用——Josephus问题(顺序)-The subject of the application of linear- Josephus problem (order of) the subject of the application of linear- Josephus problem (order
JOSEPHUS
- 著名的约瑟夫环问题,采用链表数据结构 已知n个人(以编号1,2,3...n分别表示)围坐在一张圆桌周围。从编号为k的人开始报数,数到m的那个人出列;他的下一个人又从1开始报数,数到m的那个人又出列;依此规律重复下去,直到圆桌周围的人全部出列。 例如:n = 9, k = 1, m = 5 【解答】 出局人的顺序为5, 1, 7, 4, 3, 6, 9, 2, 8。-well-known Josephus Problem,using link list method
Josephusproblem
- Josephus problem 的实现程序-the realization of the Josephus problem
Josephus--problem
- 约瑟夫斯(Josephus)问题的一种描述是:编号为1,2,…,n的n个人按顺时针方向围坐一圈,每人持有一个密码(正整数)。一开始任选一个正整数作为报数上限值m,从第一个人开始按顺时针方向自1开始报数,报到m时停止报数。报m的人出列,将他的密码作为新的m值,从他在顺时针方向下一个人开始重新从1报数,如此下去,直至所有的人全部出列为止。试设计一个程序,按出列顺序印出各人编号。-Josephus (Josephus) a descr iption of the problem are: number
Josephus-problem
- 约瑟夫问题 假设有n个小孩坐成一个环,假如从第一个小孩开始数,如果数到m个小孩,则该小孩离开,问最后留下的小孩是第几个小孩? -The Josephus problem.Assuming n students sit in a ring.we start count from the first student.when we count m,the student who has the number of m musts leave.wo now ask the last one s
Josephus-Problem
- 约瑟夫问题(Josephus Problem)据说著名犹太历史学家 Josephus有过以下的故事:在罗马人占领乔塔帕特后,39 个犹太人与Josephus及他的朋友躲到一个洞中,39个犹太人决定宁愿死也不要被敌人到,于是决定了一个自杀方式,41个人排成一个圆圈,由第1个人开始报数,每报数到第3人该人就必须自杀,然后再由下一个重新报数,直到所有人都自杀身亡为止。 然而Josephus 和他的朋友并不想遵从,Josephus要他的朋友先假装遵从,他将朋友与自己安排在第16个与第31个位置,于是逃过
the-Josephus-problem
- 利用建立双向循环链表来解决约瑟夫环的问题-Doubly linked list to solve the Josephus problem
The-circular-list-Josephus-problem
- 循环链表josephus问题。设有n个人围圈,现从第s个人开始报数,数到第m个人出列,然后从出列的下一个人从新开始报数,数到第m个人又出列,如此反复,直到所有人出列-Circular list josephus problem. Suppose there are n individuals in a circle, is from the first s individual reported the number of individuals out to the m-number colu
Josephus-Problem
- 约瑟夫问题的链表实现,包含源代码(c语言实现)-solve of Josephus Problem
Josephus-problem
- 该程序能够根据使用者的需要,解决约瑟夫环问题。-The program can be based on user needs,to solve Josephus problem.
1.Josephus-problem
- 约瑟夫问题是个有名的问题:N个人围成一圈,从第一个开始报数,第M个将被杀掉,最后剩下一个,其余人都将被杀掉。例如N=6,M=5,被杀掉的顺序是:5,4,6,2,3,1。-The Josephus problem is the following game: N people, numbered 1 to N, are sitting in a circle. Starting at person 1, a hot potato is passed. After M passes, the per
josephus problem
- 分别通过顺序表和链表的方式,利用C++实现约瑟夫斯问题(C++ implementation of the Josephus problem)
josephus
- 通过c语言数组算法解决josephus问题,m个人围成一圈,从第一个小孩开始顺时针方向每数到第n个小孩时这个小孩离开,最后剩下的小孩是胜利者。求第几个小孩为胜利者(C language array algorithm to solve the Josephus problem, m individual circle, from the first child began to count clockwise every n children, the child left, and final