Includes
For given two sequneces A={a0,a1,...,an−1} and B={b0,b1,...,bm−1}, determine whether all elements of B are included in A.
Note that, elements of A and B are sorted by ascending order respectively.
Time Limit | $1$ 秒/Second(s) | Memory Limit | $512$ 兆字节/Megabyte(s) |
提交总数 | $14$ | 正确数量 | $12$ | "
裁判形式 | 标准裁判/Standard Judge | 我的状态 | 尚未尝试 |
难度 | 分类标签 | STL |
Includes
For given two sequneces A={a0,a1,...,an−1} and B={b0,b1,...,bm−1}, determine whether all elements of B are included in A.
Note that, elements of A and B are sorted by ascending order respectively.
The input is given in the following format.
n
a0 a1,...,an−1
m
b0 b1,...,bm−1
The number of elements in A and its elements ai are given in the first and second lines respectively.
The number of elements in B and its elements bi are given in the third and fourth lines respectively.
4
1 2 3 4
2
2 4
1
1≤n,m≤200,000
−1,000,000,000≤a0< a1< ...< an−1≤1,000,000,000
−1,000,000,000≤b0< b1< ...< bm−1≤1,000,000,000
本题记录 | 用 户(点击查看用户) | 运行号(点击购买题解) | 时 间 |
---|---|---|---|
算法最快[$0 $ms] | Qiqy | 609012 | 2020-07-31 08:28:37 |
内存最少[$1704 $KB] | Qiqy | 609012 | 2020-07-31 08:28:37 |
第一AC | 计爱玲 | 282703 | 2018-10-07 21:23:40 |
第一挑战 | 计爱玲 | 282703 | 2018-10-07 21:23:40 |
竞赛编号 | 竞赛名称 | 竞赛时间 | 访问比赛 |
---|