Submission #2972231


Source Code Expand

#include<bits/stdc++.h>
using namespace std;
int x[1000001];
int main(){
	int n,a,b,i,t=0;
	scanf("%d%d%d",&n,&a,&b);
	for(i=1;i<=n;i++)
	{
		scanf("%d",&x[i]);
		if(x[i]<a||x[i]>=b)t++;
	}
	printf("%d\n",t);
	return 0;
}

Submission Info

Submission Time
Task A - A Barricade
User luogu_bot3
Language C++ (GCC 5.4.1)
Score 66
Code Size 234 Byte
Status AC
Exec Time 1 ms
Memory 256 KB

Compile Error

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

Judge Result

Set Name All
Score / Max Score 66 / 66
Status
AC × 9
Set Name Test Cases
All 00_sample.txt, 01_sample.txt, 02_sampe.txt, 03_sample.txt, corner_case_03.txt, corner_case_04.txt, random_case_00.txt, random_case_01.txt, random_case_02.txt
Case Name Status Exec Time Memory
00_sample.txt AC 1 ms 256 KB
01_sample.txt AC 1 ms 256 KB
02_sampe.txt AC 1 ms 256 KB
03_sample.txt AC 1 ms 256 KB
corner_case_03.txt AC 1 ms 256 KB
corner_case_04.txt AC 1 ms 256 KB
random_case_00.txt AC 1 ms 256 KB
random_case_01.txt AC 1 ms 256 KB
random_case_02.txt AC 1 ms 256 KB