Submission #74127556


Source Code Expand

#include<stdio.h>
int main(){
    int count;
    int x;
    int y;
    int L;
    int R;
    int D;
    int U;
    scanf("%d" , &L);
    scanf("%d" , &R);
    scanf("%d" , &D);
    scanf("%d" , &U);
    for (int i=L ; i<R+1 ; i++){
        for (int j=D ; j<U+1 ; j++){


            if (i>0){
                x=i;
            }else{
                x=-i;
            }
            if (j>0){
                y=j;
            }else{
                y=-j;
            }

            if (x>=y && x%2==0){
                count=count+1;
            }
            if (x<y && y%2==0){
                count=count+1;
            }
        

            }
        }
    printf("%d" , count);
}

Submission Info

Submission Time
Task D - Make Target 2
User Priyadarshi100
Language C23 (Clang 21.1.0)
Score 0
Code Size 723 Byte
Status WA
Exec Time > 2000 ms
Memory 1996 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 0 / 425
Status
AC × 1
WA × 1
AC × 5
WA × 7
TLE × 17
Set Name Test Cases
Sample sample00.txt, sample01.txt
All sample00.txt, sample01.txt, testcase00.txt, testcase01.txt, testcase02.txt, testcase03.txt, testcase04.txt, testcase05.txt, testcase06.txt, testcase07.txt, testcase08.txt, testcase09.txt, testcase10.txt, testcase11.txt, testcase12.txt, testcase13.txt, testcase14.txt, testcase15.txt, testcase16.txt, testcase17.txt, testcase18.txt, testcase19.txt, testcase20.txt, testcase21.txt, testcase22.txt, testcase23.txt, testcase24.txt, testcase25.txt, testcase26.txt
Case Name Status Exec Time Memory
sample00.txt AC 0 ms 1996 KiB
sample01.txt WA 0 ms 1948 KiB
testcase00.txt TLE > 2000 ms 1680 KiB
testcase01.txt TLE > 2000 ms 1732 KiB
testcase02.txt TLE > 2000 ms 1820 KiB
testcase03.txt TLE > 2000 ms 1720 KiB
testcase04.txt TLE > 2000 ms 1796 KiB
testcase05.txt TLE > 2000 ms 1720 KiB
testcase06.txt TLE > 2000 ms 1720 KiB
testcase07.txt TLE > 2000 ms 1680 KiB
testcase08.txt TLE > 2000 ms 1820 KiB
testcase09.txt WA 530 ms 1908 KiB
testcase10.txt TLE > 2000 ms 1820 KiB
testcase11.txt TLE > 2000 ms 1812 KiB
testcase12.txt WA 1 ms 1980 KiB
testcase13.txt TLE > 2000 ms 1820 KiB
testcase14.txt WA 1131 ms 1904 KiB
testcase15.txt AC 2 ms 1996 KiB
testcase16.txt TLE > 2000 ms 1768 KiB
testcase17.txt WA 882 ms 1984 KiB
testcase18.txt TLE > 2000 ms 1824 KiB
testcase19.txt TLE > 2000 ms 1720 KiB
testcase20.txt TLE > 2000 ms 1804 KiB
testcase21.txt TLE > 2000 ms 1764 KiB
testcase22.txt AC 1 ms 1980 KiB
testcase23.txt AC 0 ms 1908 KiB
testcase24.txt AC 0 ms 1948 KiB
testcase25.txt WA 1 ms 1916 KiB
testcase26.txt WA 1 ms 1920 KiB