文件名称:bukepai

  • 所属分类:
  • JSP源码/Java
  • 资源属性:
  • [Text]
  • 上传时间:
  • 2014-05-22
  • 文件大小:
  • 1kb
  • 下载次数:
  • 0次
  • 提 供 者:
  • 杨*
  • 相关连接:
  • 下载说明:
  • 别用迅雷下载,失败请重下,重下不扣分!

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

1.写一个程序提示用户键入某一货币数量(以分为单位),该程序应计算出如何用最少量的1元,50分,10分和1分硬币得到该数目。如195分最少可以用一个1元硬币,1个50分硬币,4个10分硬币和5个1分硬币组成。

注意:可以不用数组。

2.写一个程序可以对两个字符串进行测试,得知第一个字符串是否包含在第二个字符串中。如字符串”PEN”包含在字符串“INDEPENDENT”中。

可以利用字符串类的方法

boolean regionMatches(int toffset, String other, int ooffset, int len)

关于本方法的说明可以在网上(如ORACLED的网站)查到,

(b)改进程序,当第一个字符串包含在第二个字符串中时,显示第一个字符串在第二个字符串中的起始位置。

(c)改进程序,即使当用户输入顺序错误时(第一个是长字符串,第二个是短字符串),能自动在长字符串中搜寻短字符串。

同花色的13张扑克牌,按照顺序A,2,3……10 J Q K排成一圆圈,从A开始,总是按照同一方向数。每数到第10张,便拿出来,再从下一个开始数,如此继续下去,问:最后剩下的那张扑克牌是哪张?

-1. Write a program that prompts the user to type in a certain currency amount (in divided into unit), the program should calculate the how to use the least amount of 1 yuan, 50 points, 10 points and penny to get the number 1. Such as 195 points can be used at least a $1 COINS, a 50 cent coin, four 10 points of COINS and five 1 cent coin.

Note: you can need not an array.

2. Write a program to test two strings, learned that the first string is included in the second string. Such as the string "PEN" included in the string "INDEPENDENT".

Can the method of using string class

Boolean regionMatches (int toffset, String other, int ooffset, int len)

For an explanation of this method can (such as ORACLED site) on the Internet,

(b) improvement program, when the first string contains the second string, showed the first word


(系统自动生成,下载前可以参看下载内容)

下载文件列表





扑克牌.txt

相关说明

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

相关评论

暂无评论内容.

发表评论

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

源码中国 www.ymcn.org