文件名称:3
-
所属分类:
- 标签属性:
- 上传时间:2015-12-01
-
文件大小:1.6kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
某公司在对应聘者做过一轮笔试之后,从中选出n 人继续进行面试,每位应聘者被分配了一个整数ID。
为公平起见,组织者决定利用会议室外的圆桌,按以下方法“随机”确定面试顺序:第一个到达的应聘者在圆桌周围任意选择一个位置坐下;此后到达的每位应聘者都从前一应聘者出发,沿逆时针方向围圆桌走过m 人(前一应聘者算作走过的第1 人,同一人可能经过多次),并紧邻第m 人右侧就座;所有应聘者到齐后,从最后到达者出发,绕圆桌以顺时针方向为序进行面试。
这里假定应聘者到达的时刻互异,且相对的就坐位置确定后,左、右两人之间总能插入一把椅子。
试编写一个程序,确定面试顺序。-After a company has done round of written tests for candidates, people continue to choose the n interview, each candidate is assigned an integer ID. To be fair, the organizers decided to use a round table outside the meeting room, according to the following method random interview to determine the order of: the first candidate to arrive around the round table to sit down and choose a location each candidate to reach all the previous thereafter candidates, along the counterclockwise direction around the round table who came m (previous candidates counted as the first man walked, the same person may go through times), and the right of people seated next to the first m all candidates to after Qi, starting the last arrivals, round table in a clockwise direction around the order of interviews. It is assumed that candidates mutually different arrival time, and the relative seating position is determined, the total can be inserted into a chair between the left and right two. Try to write
为公平起见,组织者决定利用会议室外的圆桌,按以下方法“随机”确定面试顺序:第一个到达的应聘者在圆桌周围任意选择一个位置坐下;此后到达的每位应聘者都从前一应聘者出发,沿逆时针方向围圆桌走过m 人(前一应聘者算作走过的第1 人,同一人可能经过多次),并紧邻第m 人右侧就座;所有应聘者到齐后,从最后到达者出发,绕圆桌以顺时针方向为序进行面试。
这里假定应聘者到达的时刻互异,且相对的就坐位置确定后,左、右两人之间总能插入一把椅子。
试编写一个程序,确定面试顺序。-After a company has done round of written tests for candidates, people continue to choose the n interview, each candidate is assigned an integer ID. To be fair, the organizers decided to use a round table outside the meeting room, according to the following method random interview to determine the order of: the first candidate to arrive around the round table to sit down and choose a location each candidate to reach all the previous thereafter candidates, along the counterclockwise direction around the round table who came m (previous candidates counted as the first man walked, the same person may go through times), and the right of people seated next to the first m all candidates to after Qi, starting the last arrivals, round table in a clockwise direction around the order of interviews. It is assumed that candidates mutually different arrival time, and the relative seating position is determined, the total can be inserted into a chair between the left and right two. Try to write
(系统自动生成,下载前可以参看下载内容)
下载文件列表
ConsoleApplication1.vcxproj
3.cpp
3.cpp
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.