TopCoder

User's AC Ratio

100.0% (4/4)

Submission's AC Ratio

60.0% (6/10)

Tags

Description

Input Format

Output Format

Sample Input 1

3#123456789
3#65#84##
52#######
#87####31
##3#1##8#
9##863##5
#5##9#6##
13####25#
#######74
##52#63##

Sample Output 1

316578492
529134768
487629531
263415987
974863125
851792643
138947256
692351874
745286319

Sample Input 2

2?ABCD
A?B?
???C
?B??
??D?

Sample Output 2

ACBD
BDAC
DBCA
CADB

Sample Input 3

3#123456789
25####9#7
##9####85
78##5#1##
###71#32#
9##563###
1#3#####4
495##6#18
6#2897###
#3######6

Sample Output 3

251638947
349271685
786459132
568714329
924563871
173982564
495326718
612897453
837145296

Hints

Problem Source

YTP 2021 高中組復活賽 p2

Subtasks

No. Testdata Range Constraints Score
1 0~2 範例測資 0
2 0~5 無額外限制 15

Testdata and Limits

No. Time Limit (ms) Memory Limit (VSS, KiB) Output Limit (KiB) Subtasks
0 4000 262144 65536 1 2
1 4000 262144 65536 1 2
2 4000 262144 65536 1 2
3 4000 262144 65536 2
4 4000 262144 65536 2
5 4000 262144 65536 2