Submission #12601014


Source Code Expand

import sys
import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

N, M = map(int, readline().split())

A = np.arange(M)
B = 2 * M - 1 - A
B[:M//2] -= (2*M+1)

A %= N
B %= N
A += 1
B += 1
for a, b in zip(A.tolist(), B.tolist()):
    print(a,b)

Submission Info

Submission Time
Task E - Rotation Matching
User maspy
Language Python (3.8.2)
Score 500
Code Size 331 Byte
Status AC
Exec Time 165 ms
Memory 35400 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 500 / 500
Status
AC × 2
AC × 32
Set Name Test Cases
Sample Sample_01.txt, Sample_02.txt
All Sample_01.txt, Sample_02.txt, basic_01.txt, basic_02.txt, basic_03.txt, basic_04.txt, basic_05.txt, basic_06.txt, basic_07.txt, basic_08.txt, basic_09.txt, basic_10.txt, rand_large01.txt, rand_large02.txt, rand_large03.txt, rand_large04.txt, rand_large05.txt, rand_small01.txt, rand_small02.txt, rand_small03.txt, rand_small04.txt, rand_small05.txt, second_01.txt, second_02.txt, second_03.txt, second_04.txt, second_05.txt, second_06.txt, second_07.txt, second_08.txt, second_09.txt, second_10.txt
Case Name Status Exec Time Memory
Sample_01.txt AC 107 ms 27048 KiB
Sample_02.txt AC 105 ms 26956 KiB
basic_01.txt AC 106 ms 27208 KiB
basic_02.txt AC 100 ms 26776 KiB
basic_03.txt AC 108 ms 26984 KiB
basic_04.txt AC 103 ms 27180 KiB
basic_05.txt AC 101 ms 26708 KiB
basic_06.txt AC 152 ms 33544 KiB
basic_07.txt AC 165 ms 35400 KiB
basic_08.txt AC 108 ms 27420 KiB
basic_09.txt AC 120 ms 28880 KiB
basic_10.txt AC 134 ms 30392 KiB
rand_large01.txt AC 107 ms 27220 KiB
rand_large02.txt AC 107 ms 27336 KiB
rand_large03.txt AC 109 ms 27480 KiB
rand_large04.txt AC 105 ms 27272 KiB
rand_large05.txt AC 125 ms 29720 KiB
rand_small01.txt AC 103 ms 26988 KiB
rand_small02.txt AC 107 ms 26984 KiB
rand_small03.txt AC 105 ms 27096 KiB
rand_small04.txt AC 104 ms 26984 KiB
rand_small05.txt AC 102 ms 27004 KiB
second_01.txt AC 105 ms 27040 KiB
second_02.txt AC 106 ms 26972 KiB
second_03.txt AC 104 ms 26780 KiB
second_04.txt AC 103 ms 26836 KiB
second_05.txt AC 108 ms 27092 KiB
second_06.txt AC 111 ms 27172 KiB
second_07.txt AC 122 ms 28784 KiB
second_08.txt AC 128 ms 30236 KiB
second_09.txt AC 141 ms 31776 KiB
second_10.txt AC 151 ms 33144 KiB