文件名称:yuesefu

介绍说明--下载内容均来自于网络,请自行研究使用

约瑟夫环问题:设编号为1,2,3,……,n的n(n>0)个人按顺时针方向围坐一圈,每个人持有一个正整数密码。开始时任选一个正整数做为报数上限m,从第一个人开始顺时针方向自1起顺序报数,报到m是停止报数,报m的人出列,将他的密码作为新的m值,从他的下一个人开始重新从1报数。如此下去,直到所有人全部出列为止。令n最大值取30。要求设计一个程序模拟此过程,求出出列编号序列。-Josephus problem: Let numbered 1,2,3, ... ..., n of the n (n> 0) individuals sitting around a circle clockwise, each person has a positive integer password. Choose the beginning of a positive integer as the reported maximum number of m, starting clockwise from the first person from the sequence reported from a number of m is to stop the newspaper to report the number of people reported m the column, his password as a new m value, the next person from the beginning of his re-reported from a number. It goes on, until all the columns up for all. Let n be the maximum take 30. To design a program to simulate this process, find out the column number sequence.
(系统自动生成,下载前可以参看下载内容)

下载文件列表

约瑟夫2\main.cpp

.......\约瑟夫2.dsp

.......\约瑟夫2.dsw

.......\约瑟夫2.ncb

.......\约瑟夫2.plg

.......\Debug\main.obj

.......\.....\vc60.idb

.......\.....\vc60.pdb

.......\.....\约瑟夫2.exe

.......\.....\约瑟夫2.ilk

.......\.....\约瑟夫2.pch

.......\.....\约瑟夫2.pdb

.......\约瑟夫2.opt

.......\Debug

约瑟夫2

相关说明

  • 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
  • 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度更多...
  • 请直接用浏览器下载本站内容,不要使用迅雷之类的下载软件,用WinRAR最新版进行解压.
  • 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
  • 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
  • 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.

相关评论

暂无评论内容.

发表评论

*主  题:
*内  容:
*验 证 码:

源码中国 www.ymcn.org