Java 快读模板

import java.io.*;

public class Main {
    static PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));

    public static void main(String[] args) throws IOException {
        int a = Input.nextInt();
        double b = Input.nextDouble();
        String str = Input.readLine();
        out.println(a);
        out.println(b);
        out.println(str);
        out.flush();
    }
}

class Input {
    static StreamTokenizer streamTokenizer = new StreamTokenizer(new BufferedReader(new InputStreamReader(System.in)));
    static BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(System.in));

    static String readLine() throws IOException {
        return bufferedReader.readLine();
    }

    static double nextDouble() throws IOException {
        streamTokenizer.nextToken();
        return (double) streamTokenizer.nval;
    }

    static int nextInt() throws IOException {
        streamTokenizer.nextToken();
        return (int) streamTokenizer.nval;
    }
}
全部评论

相关推荐

点赞 收藏 评论
分享
牛客网
牛客企业服务