ImageVerifierCode 换一换
格式:PPT , 页数:90 ,大小:244KB ,
资源ID:1060631      下载积分:10 文钱
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,省得不是一点点
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.wenke99.com/d-1060631.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: QQ登录   微博登录 

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(湖南大学第二届程序设计大赛赛题分析.PPT)为本站会员(国***)主动上传,文客久久仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知文客久久(发送邮件至hr@wenke99.com或直接QQ联系客服),我们立即给予删除!

湖南大学第二届程序设计大赛赛题分析.PPT

1、湖南大学第二届程序设计大赛赛题分析主讲:吴昊Hunan University 2006 the 2nd Programming Contest Array The milliard Vasyas function Computer Robot In The Field Equilateral triangle Fragment Assembly Towards Zero Hamming Distance Overlapping Rectangles James BondProblem A Array Time Limit: 1 second Memory Limit: 32,768 KB De

2、scription (1) Imperative programming languages allow the use of both linear and multi-dimensional arrays. E.g. in Pascal for an array named X the expression array 0.2, 0.1, 0.3 declares a three-dimensional array having the following boundaries for each dimension: 0.2, 0.1, 0.3. (We consider only zer

3、o-based arrays here though other values are possible in Pascal for lower bounds of each dimension.) It is always possible to determine the order in which the items of the array are enumerated. Consider that this order is determined by the principle “right-hand indices change faster“. This means that

4、 the last (rightmost) index iterates through all possible values, then the index that is next to it (second from the right) changes its value by 1, and the last index iterates between the lower and upper boundaries again, and so on.Description(2) Example. The items of the array mentioned above are e

5、numerated in the following order: X0,0,0, X0,0,1, X0,0,2, X0,0,3, X0,1,0, X0,1,1, X0,1,2, X0,1,3, X1,0,0, X1,0,1, X1,0,2, X1,0,3, X1,1,0, X1,1,1, X1,1,2, X1,1,3, X2,0,0, X2,0,1, X2,0,2, X2,0,3, X2,1,0, X2,1,1, X2,1,2, X2,1,3. Let an n-ary array X is declared as array0.k1, 0.k2, ., 0.kn. The theory s

6、ays that the order P of any item Xi1, i2, , in is calculated as P(i1, i2, , in) = 1 + D1*i1+D2*i2+ Dn*in, if we use the enumeration described above. Here D1, D2, ., Dn are so-called index multipliers. Example. For the array in discussion the index multipliers are D1=8, D2=4, D3=1. Then, for example,

7、 the order of X1,0,3 will be P(1,0,3) = 1+8*1+4*0+1*3 = 12. Your task is to calculate the unknown upper boundaries (k1, k2, , kn) for given index multipliers D1, D2, ., Dn and total number of items s in the array.Input The first line of the input contains n the number of dimensions (1 = n = 20) and

8、s the total number of items in the array (1 = s MaxLongInt=231-1). The following n lines contain the index multipliers D1, D2, ., Dn.Output Determine the upper boundaries for each dimension of the array in order: k1, k2, ., kn (0 ki = 1000). The numbers in the output may be delimited with spaces and/or CR/LF characters.Sample Input 3 24 8 4 1Sample Output 2 1 3数组 时间限制 :1S 内存限制 :36728K

Copyright © 2018-2021 Wenke99.com All rights reserved

工信部备案号浙ICP备20026746号-2  

公安局备案号:浙公网安备33038302330469号

本站为C2C交文档易平台,即用户上传的文档直接卖给下载用户,本站只是网络服务中间平台,所有原创文档下载所得归上传人所有,若您发现上传作品侵犯了您的权利,请立刻联系网站客服并提供证据,平台将在3个工作日内予以改正。