黑龙江省第七届大学生程序设计竞赛-Mysterious Organization
描述
GFW had intercepted billions of illegal links successfully. It has much more effect. Today, GFW intercepted a message of a mysterious organization. This mysterious organization package the message in legitimate URL.
To find the Black Hand behind the scenes, GFW didn’t shield the IP. Instead, it chooses to tap the massage. Because the messages are packaged in URL, and encrypted by the way we don’t know, GFW chooses to monitor all the URL passed, to get enough information to find the Black Hand behind the scenes.
This kind of URL is easy to find. This kind of URL including the word’ manure’. Your task is to find how many URL is this kind.
输入
Input has only one case, it has multiple lines. Each line has a string standing for the URL passing GFW. The length of the string is less than 256 without blank in it. There won’t be more than 256 lines in the cases.
输出
Output one line standing for the number of URL GFW needs.
样例输入
http://61.135.169.105//manur//whoistheboss
http://61.135.169.105//mare//whoistheboss
https://61.135.169.105//manure//Iamtheboss
样例输出
#include<iostream>
#include<cstring>
using namespace std;
int main()
{
char a[300];
int sum=0;
while(cin>>a)
{ for(int i=0;i<strlen(a)-5;i++)
{
if(a[i]=='m'&&a[i+1]=='a'&&a[i+2]=='n'&&a[i+3]=='u'&&a[i+4]=='r'&&a[i+5]=='e')
sum++;
}
}
cout<<sum<<endl;
return 0;
}
黑龙江省第七届大学生程序设计竞赛-Mysterious Organization的更多相关文章
- 黑龙江省第七届大学生程序设计竞赛-Heap
描述 A heap is a full binary tree; for each node, its key is greater than its two sub-node’s key. Two ...
- “亚信科技杯”南邮第七届大学生程序设计竞赛之网络预赛 A noj 2073 FFF [ 二分图最大权匹配 || 最大费用最大流 ]
传送门 FFF 时间限制(普通/Java) : 1000 MS/ 3000 MS 运行内存限制 : 65536 KByte总提交 : 145 测试通过 : 13 ...
- 2015湘潭市第七届大学生程序设计竞赛 —— Fraction
题目大意: 小数化分数,但是分母限制在[1,1000],很明显的枚举,但是在赛场上的时候傻逼了,无论怎么枚举,怎么二分就是wa,wa到死···········. (ps:我要给出题人寄刀片~~~~), ...
- 《内蒙古自治区第十三届大学生程序设计竞赛试题_H 公孙玉龙》
这个题有点小坑,最坑的地方就是 输入的b 变量 有可能 是 负数 ! 负数 ! 负数! 对 ,你没有看错,就是负数,坑死我了, 一直都是 content.charAt(0) 判断 ...
- 浙江财经大学第十五届大学生程序设计竞赛------B 烦恼先生打麻将
问题 B: B - 烦恼先生打麻将 时间限制: 1 Sec 内存限制: 256 MB提交: 8 解决: 5[提交][状态][讨论版] 题目描述 输入 6 6 Z D 1S 1S 9W 5W 2S ...
- ZOJ 4100 浙江省第16届大学生程序设计竞赛 A题 Vertices in the Pocket 线段树+并查集
正赛的时候完全没看这个题,事后winterzz告诉我他想出来的解法. 首先题意是给出n个点,m次操作. 操作有一种是连接两个点,另一种是求此时再为这个图连k条边,最少和最多能有几个联通块. 最少的求法 ...
- River Crossing---河南省第六届大学生程序设计竞赛
题目描述 Afandi is herding N sheep across the expanses of grassland when he finds himself blocked by a ...
- ZOJ 4103 浙江省第16届大学生程序设计竞赛 D题 Traveler 构造
这个题,正赛的时候也没有过,不过其实已经有了正确的解法,可惜时间不多了,就没有去尝试. 题意是有n个点,i点能通向i-1,然后i和i*2.i*2+1互通. 请你构造一种路径从1能走完所有点,并且不重复 ...
- Contest - 中南大学第六届大学生程序设计竞赛(Semilive)
题1:1160十进制-十六进制 注意他给的数据范围 2^31,int是 2^31-1 #include<iostream> using namespace std; int main() ...
随机推荐
- nodejs hello world (调用文件执行没反应)
今天学习了node.js ,来看一下hello world 的写法. 1. 首先安装node.js的驱动文件.http://nodejs.org/ 2. a:安装好node之后,在CMD窗口输入nod ...
- CSS样式属性
一.背景与前景 1.背景: 2.前景字体: (二)边界和边框 border(表格边框.样式等).margin(表外间距).padding(内容与单元格间距). margin(外边距)对自身不会有变化, ...
- UILabel显示html文本
NSString * htmlString = @"<html><body> Some html string \n <font size=\"13\ ...
- MySQL 5.7.14 安装
http://www.cnblogs.com/zcGu/articles/5740936.html 因笔者个人需要需要在本机安装Mysql,先将安装过程记录如下,希望对他人有所参考. 一, 1, 进入 ...
- HDU 1045(质因数分解)
Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Description Tomor ...
- 如何隐藏DLL中,导出函数的名称?
一.引言 很多时候,我们写了一个Dll,不希望别人通过DLL查看工具,看到我们的导出函数名称.可以通过以下步骤实现: 1. 在def函数中做如下定义: LIBRARY EXPORTS HideFunc ...
- C#中foreach语句的迭代器实现机制
C#中的foreach语句可用于循环遍历某个集合中的元素,而所有的只要支持了IEnumerable或IEnumerable<T>泛型接口的类型都是可以 用foreach遍历的.其具体的遍历 ...
- U-Boot在FL2440上移植(三)----支持NAND Flash
<一>支持NAND Flash 1. 首先在配置文件 include/config/fl2440.h 的宏 CONFIG_COMMANDS 中增加 CFG_CMD_NAND, #defin ...
- Delphi 中 COM 实现研究手记(一)
前言 前些日子用 Delphi 写了一个 Windows 外壳扩展程序,大家知道 Windows 外壳扩展实际上就是 COM 的一种应用 -- Shell COM,虽然整个程序写得还算比较顺利,但写完 ...
- python异常处理URLError,HTTPError,Wrapping,
们在使用爬虫来抓取网页内容的时候,HTTP异常是必须要注意的一项,所以本文,我们来详细探寻一下HTTP异常处理的相关内容,通过一些具体的实例来分析一下,非常的简单,但是却很实用. 先来说一说HTT ...