登录
首页 » 数据结构 » 求解约瑟夫问题。设有n个人围成一个圆圈坐下,对所有围从的人从某个位置开始编号为1,2,3,……,n,从编号为1的人开始报数1,报数依交进行,报数n的人即出列,下...

求解约瑟夫问题。设有n个人围成一个圆圈坐下,对所有围从的人从某个位置开始编号为1,2,3,……,n,从编号为1的人开始报数1,报数依交进行,报数n的人即出列,下...

于 2022-05-21 发布 文件大小:7.84 kB
0 108
下载积分: 2 下载次数: 1

代码说明:

求解约瑟夫问题。设有n个人围成一个圆圈坐下,对所有围从的人从某个位置开始编号为1,2,3,……,n,从编号为1的人开始报数1,报数依交进行,报数n的人即出列,下一个人从1开始报数,再报数m的人便是第二个出列的人如此重复下去,直到最后一个人出列为止,于是便得到一个出列的顺序,这称之为约瑟夫(Josephu)问题。-solving problems. N individuals have formed a circle to sit down, all right Wai from the start from a position of No. 1, 2, 3, ..., n, for a number of people reported a few, according to several newspaper pay, the newspaper n ie the out, the next person was from the beginning a few , and reported m is the second out of this series continue to repeat until the final out in a series, then get a series out of order, which called Joseph (Josephu) problem.

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论


0 个回复

  • 本人收集的一些经典算法实现,感觉还不错
    本人收集的一些数据结构经典算法实现,感觉还不错-shu ju jie gou jing dian suan fa shi xian
    2022-08-25 10:21:12下载
    积分:1
  • 关于:
    About: hamsterdb is a database engine written in ANSI C. It supports a B+Tree index structure, uses memory mapped I/O (if available), supports cursors, and can create in-memory databases. Release focus: Major feature enhancements Changes: This release comes with many changes and new features. It can manage multiple databases in one file. A new flag (HAM_LOCK_EXCLUSIVE) places an exclusive lock on the file. hamsterdb was ported to Windows CE, and the Solution file for Visual Studio 2005 now supports builds for x64. Several minor bugs were fixed, performance was improved, and small API changes occurred. Pre-built libraries for Windows (32-bit and 64-bit) are available for download. Author: cruppstahl
    2023-08-10 06:40:03下载
    积分:1
  • 医院挂号系统叫号系统
    用VB编写的医院挂号叫号系统,代码简介,功能强大,值得一看的VB医院叫号软件,
    2022-05-16 11:26:44下载
    积分:1
  • 用C实现的基于O
    用C实现的基于O-tree的ic设计布图布线工具源代码,有相关文档-C realized based on O-tree-id wiring layout design tools source code, related documentation
    2022-05-31 07:35:33下载
    积分:1
  • 小型库源代码较多,请耐心审阅勿用于商业交易,一经发现后果自负...
    小型数据库源代码较多,请耐心审阅勿用于商业交易,一经发现后果自负-small database source code more, not patience scrutiny for commercial transactions, the one found responsible for any consequences! !
    2022-06-12 22:29:41下载
    积分:1
  • 中常用的动态演示,可以帮助初学者更好的理解其的实现...
    数据结构中常用结构的动态演示,可以帮助初学者更好的理解其结构的实现-data structure used dynamic structure of the demonstration, and can help beginners a better understanding of its structure to achieve
    2022-02-07 07:48:28下载
    积分:1
  • 同一个库开发的系统,有源代码和发布版本
    同一个数据库开发的系统,有源代码和发布版本-with a database development systems, and active code releases
    2022-05-17 05:06:43下载
    积分:1
  • 这是一个PB小程序 是实现模糊查询的.这是一个PB的小程序,实现模糊查询的 这是一个PB的小程序,实现模糊查询的...
    这是一个PB小程序 是实现模糊查询的.这是一个PB的小程序,实现模糊查询的 这是一个PB的小程序,实现模糊查询的-PB This a small program is vague inquiries. This a small program PB, Fuzzy inquiry, which is a PB of small programs to achieve fu zzy inquiry, which is a PB of small programs to achieve fuzzy inquiry, which is the one PB small program for the realization of fuzzy
    2022-07-09 23:16:39下载
    积分:1
  • UTE
    UTE - (U)niversal ASP (T)able (E)ditor 万能数据管理(管理后台)-oldest- (U) niversal ASP (T) able (E) Editor omnipotent data management (management background)
    2023-05-22 00:30:03下载
    积分:1
  • At 0 and 1 backpack case for problem
    在0和1情况下进行背包问题解决,涉及多个物体的重量和价值,求得最大价值量以及分配方案。-At 0 and 1 backpack case for problem-solving, involving more than the weight of objects and values, as well as to achieve maximum value distribution program.
    2022-02-01 11:38:47下载
    积分:1
  • 696518资源总数
  • 104629会员总数
  • 9今日下载