i 绝望

依然

Miss Lang

java流。基础

总结:read()方法返回类型是int型??不知道该怎么用好循环》

package com.da;

import java.io.*;

public class fgbv {
	public static void main(String[] args) throws IOException {
		BufferedReader bb = new BufferedReader(new InputStreamReader(System.in));
		char c;
		System.out.println("enter a line");
		do {
			c = (char) bb.read();
			System.out.print(c);
		} while (c != 'd');

	}

}

  

 

posted on 2013-11-13 07:52  juewang  阅读(161)  评论(0编辑  收藏  举报

绝望依然

Miss Lang