小编Jco*_*der的帖子

Java问题时间限制超出问题

我正在编码一个问题(参考--http://www.codechef.com/FEB11/problems/THREECLR/)

以下是我的代码

import java.io.*;
import java.util.*;


public class Main {

 static String ReadLn (int maxLg)  // utility function to read from stdin
    {
        byte lin[] = new byte [maxLg];
        int lg = 0, car = -1;
        String line = "";

        try
        {
            while (lg < maxLg)
            {
                car = System.in.read();
                if ((car < 0) || (car == '\n')) break;
                lin [lg++] += car;
            }
        }
        catch (IOException e)
        {
            return (null);
        }

        if ((car < 0) && (lg == 0)) …
Run Code Online (Sandbox Code Playgroud)

java algorithm execution-time

6
推荐指数
1
解决办法
6495
查看次数

标签 统计

algorithm ×1

execution-time ×1

java ×1