#include <stdio.h>
const int maxn = ;
int a[maxn] = {};
int b[maxn]= {};
int main(void) {
int n;
while(scanf("%d", &n) != EOF){
for(int i=; i<n; i++){
scanf("%d", a+i);
} int m;
scanf("%d", &m);
int j;
for(int i=; i<m; i++){
scanf("%d", b+i);
for(j=; j<n; j++){
if(a[j] == b[i]) break;
}
if (j==n) printf("NO\n");
else printf("YES\n");
} }
}

3.2-1937 Problem D的更多相关文章

  1. HDU3032 Nim or not Nim?(Lasker’s Nim游戏)

    Nim or not Nim? Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)T ...

  2. HDU 1937 F - Finding Seats 枚举

    F - Finding Seats Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64u S ...

  3. 1199 Problem B: 大小关系

    求有限集传递闭包的 Floyd Warshall 算法(矩阵实现) 其实就三重循环.zzuoj 1199 题 链接 http://acm.zzu.edu.cn:8000/problem.php?id= ...

  4. No-args constructor for class X does not exist. Register an InstanceCreator with Gson for this type to fix this problem.

    Gson解析JSON字符串时出现了下面的错误: No-args constructor for class X does not exist. Register an InstanceCreator ...

  5. C - NP-Hard Problem(二分图判定-染色法)

    C - NP-Hard Problem Crawling in process... Crawling failed Time Limit:2000MS     Memory Limit:262144 ...

  6. Time Consume Problem

    I joined the NodeJS online Course three weeks ago, but now I'm late about 2 weeks. I pay the codesch ...

  7. Programming Contest Problem Types

        Programming Contest Problem Types Hal Burch conducted an analysis over spring break of 1999 and ...

  8. hdu1032 Train Problem II (卡特兰数)

    题意: 给你一个数n,表示有n辆火车,编号从1到n,入站,问你有多少种出站的可能.    (题于文末) 知识点: ps:百度百科的卡特兰数讲的不错,注意看其参考的博客. 卡特兰数(Catalan):前 ...

  9. BZOJ2301: [HAOI2011]Problem b[莫比乌斯反演 容斥原理]【学习笔记】

    2301: [HAOI2011]Problem b Time Limit: 50 Sec  Memory Limit: 256 MBSubmit: 4032  Solved: 1817[Submit] ...

  10. [LeetCode] Water and Jug Problem 水罐问题

    You are given two jugs with capacities x and y litres. There is an infinite amount of water supply a ...

随机推荐

  1. loadrunner中面向目标场景的设计

    在一个面向目标的方案中,可以定义五种类型的目标:虚拟用户数.每秒点击次数(仅 Web Vuser).每秒事务数.每分钟页面数(仅 Web Vuser)或方案的事务响应时间.使用“编辑方案目标”对话框可 ...

  2. App自动更新(DownloadManager下载器)

    一.开门见山 代码: object AppUpdateManager { const val APP_UPDATE_APK = "update.apk" private var b ...

  3. selenium + firefox驱动版本对应。

    1)selenium 2.51.0====firefox 46 selenium 3.11.0 ====firefox 56 后来发现最新的火狐浏览器好多插件都不能用了.所以果断回到46.对应的2.5 ...

  4. [数据结构]P1.2 队列

    * 注: 本文/本系列谢绝转载,如有转载,本人有权利追究相应责任. 2019年4月8日 Stan Zhang 2019年4月8日  格物致知,经世致用. 队列是一种先进先出FIFO的模型,常见操作有: ...

  5. English trip EM2-LP-4B At School Teacher:Russell

    课上内容(Lesson) Where is Loki a student?  Loki is in Meten, BaobaoStreet, Chengdu. What is he studying? ...

  6. icpc2018-焦作-D-几何模拟

    https://nanti.jisuanke.com/t/34142 上午可能是供氧不足,推的式子死活不对,晚上莫名其妙又来了一次就过了. 分两种情况讨论,如果能够完全进入弯道答案就是固定的就是: s ...

  7. 在git服务器上创建项目过程及遇到的问题

    一: 登录git服务器,输入用户名,密码等 二: New Project 添加项目 设置组可见,项目名称等. 创建成功的项目可以看到该项目的clone地址,可以通过http,ssh两种方式来获取: 三 ...

  8. 秒懂 this(带你撸平this)

    本文讲述只针对浏览器环境. 一:全局执行 console.log(this); // Window 可以看出在全局作用域中 this 指向当前的全局对象 Window. 二:函数中执行 1. 非严格模 ...

  9. vim 插件 -- ctags

    vim ctags 插件实现代码跳转的功能.希望在一个项目中快速的找到函数,变量,宏等定义的地方. 下载 http://ctags.sourceforge.net/ 安装 tar -jxvf ctag ...

  10. css3的transform-origin配合scale,控制动画,实现各种hover效果

    1.底部画线,从左边开始,右边结束 html: <div class="silde-txt">底部划线</div> css: <style>.s ...