南华大学ACM新生训练.docVIP

  1. 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
  2. 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  3. 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
  4. 4、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
  5. 5、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们
  6. 6、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
  7. 7、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
2013-6 南华大学ACM新生训练 系统使用说明: 采用PC^2系统提交,请点击桌面的用户名和密码同为teamXX ..XX为你在签名册上的标号,签名册将在你的桌面上。请找到自己的序号(用Ctrl+F 查找自己姓名)登录自己的账号交题。 交题时: 选择Submit在随后蹦出来的框中再确认选择Yes..题目提交成功..等几秒钟裁判机将返回结果..Yes为通过..No则会说明原因… 注意事项: 1、训练做题时间为19:30-22:00 程序文件请不要用中文命名和空格,否则提交会返回No - Compile error 编译不能.. 3、main请用int类型..并在结束前返回 return 0 如: int main() { …….. return 0; } 4、所有程序采用标准的输入输出,不要读写文件(也就是自己测的时候是屏幕输入输出) 5、题目的输入输出请按照题目的要求 6、No – Compile error 为编译错误,一般是你的程序名中包含非法字符或者程序缺少一些头文件 No – Wrong answer 为答案错误,请检查你的程序有无Bug No - Presentation Error 为格式错误,请检查你的程序输出格式时不是按照题目的要求来的 No –Time Limit Exceeded 为超时,你的程序效率太低,请优化算法 No – Connect staff 请找老队员具体询问 7、自己在调试时使用的system类的请在提交时删除或者用//屏蔽…. A. Even Odds Being a nonconformist, Volodya is displeased with the current state of things, particularly with the order of natural numbers (natural number is positive integer number). He is determined to rearrange them. But there are too many natural numbers, so Volodya decided to start with the first n. He writes down the following sequence of numbers: firstly all odd integers from 1 to n (in ascending order), then all even integers from 1 to n (also in ascending order). Help our hero to find out which number will stand at the position number k. Input The only line of input contains integers n and k (1≤k≤n≤1e14). Output Print the number that will stand at the position number k after Volodyas manipulations. Sample test(s) input 10 3 7 7 output 5 6 Note In the first sample Volodyas sequence will look like this: {1, 3, 5, 7, 9, 2, 4, 6, 8, 10}. The third place in the sequence is therefore occupied by the number 5. Hint 注意数据的类型 use __int64 to read data and use %I64d to output data B. Strings of Power Volodya likes listening to heavy metal and (occasionally) reading. No wonder Volodya is especially interested in texts concerning his favourite music style. Volodya calls a string powerful if it starts with heavy and e

文档评论(0)

kxiachiq + 关注
实名认证
文档贡献者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档