Toggle navigation
编程魔法师 OJ
Home
Contest
Signup
Login
Start
2023-01-28 00:00:00
CSP-S 2022 补测 重现
End
2023-02-04 00:00:00
Contest is over.
Now
2025-12-15 10:38:03
Information
Problem
Status
Standing
Clarification
Editorial
A
B
C
D
A. 树上路径
Description
Input
Output
Examples
Input
3 2 1 1 1 2 3 2 3 3
Output
2 3
Input
4 1 1 2 3 1 2 3
Output
2
Submit
Login
Login
Signup
Time Limit
1 second
Memory Limit
512 MB
Submit
×