随笔分类 - 模拟
摘要:链接:https://www.nowcoder.com/acm/contest/115/E来源:牛客网 题目描述 当你的好友给你发来一条消息,你的消息列表上就会置顶显示该好友的名字以及该好友发给你的消息总数,换句话说,你的消息列表里的好友是按跟你发消息的时间进行排序的,给你发消息的时间离当前时间越近
阅读全文
摘要:链接:https://www.nowcoder.com/acm/contest/115/C来源:牛客网 题目描述 决赛圈还剩下两个人,“伏地魔”XDD和跑毒进圈的FZL,XDD拿着狙击枪AWM瞄准并准备射击奔跑中的FZL。 XDD知道自己只有这一次机会,如果失误了,他就会被大哥FZL空中360度甩狙
阅读全文
摘要:链接:https://www.nowcoder.com/acm/contest/115/B来源:牛客网 题目描述 给出一个出生日期,比如:1999-09-09, 问:从出生那一天开始起,到今天2018-04-21为止(包括出生日期和今天),有多少天,年月日都不包含数字4? 输入描述: 第一行输入一个
阅读全文
摘要:Problem Description 有两个球在长度为L的直线跑道上运动,两端为墙。0时刻小球a以1m/s的速度从起点向终点运动,t时刻小球b以相同的速度从终点向起点运动。问T时刻两球的距离。这里小球与小球、小球与墙的碰撞均为弹性碰撞,所有过程没有能量损失。 Input 先输入一个q,代表q组数据
阅读全文
摘要:Problem Description 一天YZW参加了学校组织交际舞活动,活动的开始活动方分别给男生和女生从1-n进行编号,按照从小到大顺时针的方式进行男女搭档分配,相同编号的男女组合成一对,例如一号男生与一号女生配对,以此类推。可是YZW对其中一个小姐姐一见钟情,于是机智的他向管理员提出了两种操
阅读全文
摘要:Bash wants to become a Pokemon master one day. Although he liked a lot of Pokemon, he has always been fascinated by Bulbasaur the most. Soon, things s
阅读全文
摘要:Country of Metropolia is holding Olympiad of Metrpolises soon. It mean that all jury members of the olympiad should meet together in Metropolis (the c
阅读全文
摘要:http://acm.hdu.edu.cn/showproblem.php?pid=1296 随手练习
阅读全文
摘要:http://acm.hdu.edu.cn/showproblem.php?pid=1409 没啥好说的,至今也不知道到底错在哪里了,看了discuss才过的
阅读全文
摘要:Arpa is researching the Mexican wave. There are n spectators in the stadium, labeled from 1 to n. They start the Mexican wave at time 0. At time 1, th
阅读全文
摘要:A B Problem Statement You are given an integer sequence of length N, a1,a2,…,aN. For each 1≤i≤N, you have three choices: add 1 to ai, subtract 1 from
阅读全文
摘要:1001 求个绝对值比较大小喽 1002 把字符串出现的字母记录一下,然后遍历a-z,谁第一个没出现就输出谁 1003 Problem Statement We have N sticks with negligible thickness. The length of the i-th stick
阅读全文
摘要:http://acm.hdu.edu.cn/showproblem.php?pid=6144 解法:一个简单的模拟
阅读全文
摘要:Problem Description 度度熊喜欢着喵哈哈村的大明星——星星小姐。 为什么度度熊会喜欢星星小姐呢? 首先星星小姐笑起来非常动人,其次星星小姐唱歌也非常好听。 但这都不是最重要的,最重要的是,星星小姐拍的一手好代码! 于是度度熊关注了星星小姐的贴吧。 一开始度度熊决定每天都在星星小姐的
阅读全文
摘要:Description 女神YSJ给Martin发了一个视频。“猜猜里面哪个是我。” 女神说。作为一个脸盲,再加上多年不见,Martin已经完全不知道女神长成了什么样子,他表示完全认不出来。好在Martin手上还有一张YSJ小时候的照片,他可以拿照片和视频里的人进行特征比对,从而找出女神。为了简化问
阅读全文
摘要:The organizers of a programming contest have decided to present t-shirts to participants. There are six different t-shirts sizes in this problem: S,M,
阅读全文
摘要:Vasily exited from a store and now he wants to recheck the total price of all purchases in his bill. The bill is a string in which the names of the pu
阅读全文
摘要:Problem Description KazaQ wears socks everyday.At the beginning, he has n pairs of socks numbered from 1 to n in his closets. Every morning, he puts o
阅读全文
摘要:All our characters have hobbies. The same is true for Fedor. He enjoys shopping in the neighboring supermarket. The goods in the supermarket have uniq
阅读全文
摘要:Ilya is an experienced player in tic-tac-toe on the 4 × 4 field. He always starts and plays with Xs. He played a lot of games today with his friend Ar
阅读全文