Submission #19025483


Source Code Expand

Copy
public class Main {

    public static void main(String[] args) {
        boolean[] x=new boolean[1001];
        boolean[] y=new boolean[1001];
        boolean[] x_y=new boolean[2001];
        boolean[] xplusy=new boolean[2001];
        System.out.println(1000);
        for (int i = 0; i < 10; i++) {
            for (int j = 0; j < 10; j++) {
                for (int k = 0; k < 10; k++) {
                    System.out.println((i+100*k)+" "+(10*j+100*k));
                    x[i+100*k]=true;
                    y[10*j+100*k]=true;
                    x_y[1000 + i-10*j]=true;
                    xplusy[i+10*j+(200*k)]=true;
                }
            }
        }
        int a=0; int b=0;
        for (int i = 0; i <= 1000; i++) {
            if(x[i])a++;
            if(y[i])b++;
        }
        int c=0; int d=0;
        for (int i = 0; i <= 2000; i++) {
            if(x_y[i])c++;
            if(xplusy[i])d++;
        }
        /*
        for (int i = 0; i < 100; i++) {
            for (int j = 0; j < 2000; j+=200) {
                if(!xplusy[i+j]){
                    System.out.println("ERROR "+(i+j)+" "+xplusy[i+j]);
                }
            }
        }
        System.out.println(a+" "+b+" "+c+" "+d);*/
    }
    
}

Submission Info

Submission Time
Task B - Bowling
User CycloPolys
Language Java (OpenJDK 11.0.6)
Score 800
Code Size 1290 Byte
Status AC
Exec Time 158 ms
Memory 36568 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 800 / 800
Status
AC × 1
AC × 1
Set Name Test Cases
Sample example0.txt
All example0.txt
Case Name Status Exec Time Memory
example0.txt AC 158 ms 36568 KB