首页| JavaScript| HTML/CSS| Matlab| PHP| Python| Java| C/C++/VC++| C#| ASP| 其他|
购买积分 购买会员 激活码充值

您现在的位置是:虫虫源码 > 其他 > 输入一个文本文件来运行它的命令

输入一个文本文件来运行它的命令

  • 资源大小:17.93 kB
  • 上传时间:2021-06-30
  • 下载次数:0次
  • 浏览次数:1次
  • 资源积分:1积分
  • 标      签: java

资 源 简 介

This program solves the following problem. It accepts a filename as the single command-line parameter. The file will contain 7-bit ASCII text and each line may consist of an operation, followed by a colon, followed by a comma-separated list of numbers. For each line, perform the specified operation on the associated numbers and print (to System.out.println) the operation followed by the result. The operations are "SUM", "MIN", "MAX" and "AVERAGE" (to determine the sum, minimum, maximum and average respectively). E.g. for the file containing SUM: 1, 2, 3 MIN: 4, 3, 2, 40 AVERAGE: 2, 2 prints SUM 6 MIN 2 AVERAGE 2

相 关 资 源

您 可 能 感 兴 趣 的

同 类 别 推 荐

VIP VIP
0.236205s