QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#188962#1. I/O Test5ab100 55ms99148kbC++20702b2023-09-26 18:21:122023-09-26 18:21:13

Judging History

你现在查看的是最新测评结果

  • [2023-09-26 18:21:13]
  • 评测
  • 测评结果:100
  • 用时:55ms
  • 内存:99148kb
  • [2023-09-26 18:21:12]
  • 提交

config.txt

10000000 0

input_test

#include <cstdio>
#include <cstring>
#include <limits>
#include <sys/mman.h>
using namespace std;

static constexpr size_t buf_size = 134217728;
static constexpr size_t integer_size = 10;

char *inbuf;

inline void load() {
	inbuf = (char*) mmap(nullptr, 0x7000000, PROT_READ, MAP_PRIVATE, 0, 0);
	// inbuf[end] = '\0';
}
inline char get_next() { return *inbuf++; }
template<class T>
void scan(T &x) {
	char c = get_next();
    x = c - '0';
	while ((c = get_next()) >= '0')
		x = x * 10 + c - '0';
}

int main()
{
	int x = 1e7, y;
	long long res = 0;
	
	load();
	scan(x);
	while (x--)
	{
		scan(y);
		res += y;
	}
    printf("%lld", res);
	
	return 0;
}

output_test


详细

Subtask #1:

score: 100
Accepted

Test #1:

score: 100
Accepted
time: 55ms
memory: 99148kb

input:

10000000
413284514 147131623 704365863 704438231 565164595 334191861 275099956 646185068 681521261 862903789 236533972 378648759 695347275 756221946 692703187 646824550 454033128 278512717 567918073 839640863 888600188 811460946 133941062 147461573 763141857 175017054 767181385 702650988 809346055 1...

output:

5499645125347834

result:

points 1.0 input test passed

Subtask #2:

score: 0
Skipped