Submission #2459875


Source Code Expand

#include <stdio.h>
#include <string.h>
#include <ctype.h>
#define LL long long
#define uLL unsigned long long
int cmp(LL a,LL b,LL c,LL d)
{
	if (a==c)
	{
		return c-d;
	}
	else
	{
		return a-c;
	}
}
int main()
{
	LL i,j,k,a,b,c,ans;
	scanf("%lld%lld",&a,&b);
	ans=0;
	for (i=1;i<=12;i++)
	{
		if (cmp(i,i,a,b)<=0)
		{
			ans+=1;
		}
	}
	printf("%lld\n",ans);
	return 0;
}

Submission Info

Submission Time
Task A - Day of Takahashi
User faimerth
Language C++14 (GCC 5.4.1)
Score 100
Code Size 402 Byte
Status AC
Exec Time 0 ms
Memory 128 KB

Compile Error

./Main.cpp: In function ‘int main()’:
./Main.cpp:20:25: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
  scanf("%lld%lld",&a,&b);
                         ^

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 100 / 100
Status
AC × 3
AC × 7
Set Name Test Cases
Sample sample_01.txt, sample_02.txt, sample_03.txt
All in01.txt, in02.txt, in03.txt, in04.txt, sample_01.txt, sample_02.txt, sample_03.txt
Case Name Status Exec Time Memory
in01.txt AC 0 ms 128 KB
in02.txt AC 0 ms 128 KB
in03.txt AC 0 ms 128 KB
in04.txt AC 0 ms 128 KB
sample_01.txt AC 0 ms 128 KB
sample_02.txt AC 0 ms 128 KB
sample_03.txt AC 0 ms 128 KB