JAVA 高手请进!I/O Read Write Text

我是Java初学者现在正为一道题目难倒,放情哪位高手达人帮忙解答。题目如下:

For this program, assume you have an input file with several lines of text. Each line has a student's last name, followed by a space and then 4 numbers which represent his/her grades. Your program should read this input file and produce an output file with the same number of lines, each line showing the last name and the average of the student's scores.

Before.....

$ cat grades.txt
Bush 50 70 75 80
Clinton 85 90 95 98
Gore 90 95 98 97
Cheney 80 90 95 85
Powell 90 95 85 99
Lieberman 85 95 90 94

after......

$ cat gradeAvg.txt
Here are the average grades:
Bush 68.8
Clinton 92.0
Gore 95.0
Cheney 87.5
Powell 92.2
Lieberman 91.0

先这里谢谢了!!!!

所有跟帖: 

回复:JAVA 高手请进!I/O Read Write Te -天天古狗- 给 天天古狗 发送悄悄话 (331 bytes) () 12/08/2004 postreply 22:16:45

回复:回复:JAVA 高手请进!I/O Read Write Te -JavaDummie- 给 JavaDummie 发送悄悄话 (234 bytes) () 12/08/2004 postreply 22:22:50

回复:回复:JAVA 高手请进!I/O Read Write Te -JavaDummie- 给 JavaDummie 发送悄悄话 (130 bytes) () 12/08/2004 postreply 22:24:49

干脆直说帮我写作业着急交差不就完了? -别拿人好心当傻逼- 给 别拿人好心当傻逼 发送悄悄话 (4 bytes) () 12/08/2004 postreply 23:30:08

function inside -闲来无事者- 给 闲来无事者 发送悄悄话 (2241 bytes) () 12/09/2004 postreply 11:06:45

请您先登陆,再发跟帖!