题意:一个长度为l的走廊。两个人站在两端点。互相向对方发射某种魔法。A的魔法速度为p米/秒,B的魔法速度为q米/s,魔法相遇以后会反射。反射会发射人那里会再次发射。问两种魔法第二次相遇的时候距离A的距离。 思路:由于每种魔法的速度保持肯定不变。。所以不管第几次相遇。相遇点都是同一个。。。ans=p*(p+q)/l;
阅读更多http://codeforces.com/contest/598/problem/D
题意:给第一个地图。 ‘.’是能走的,‘’是不能走的。**每个‘.’和’‘之间有一幅画,**给出k个起点,问对于每组起点,最多能观察到多少副画。
阅读更多我经常看有人发帖问关于项目点子的事,也看到了很多回帖,我自己也回了一些常见的项目。不过我觉得只列出三两个是远远不够的,因此就收集并这个项目列表,大家要找简单的编程项目学习练手的话,可以收藏并扩散本文。这些项目并不是论文级别的,只是想抛砖引玉让大家能从中受些启发。
阅读更多题意是说,给定一个计算规则,求最终分数。
又傻逼了QAQ
遇到double类型一定要小心小心小心!
虽然我觉得0.3*x一定是整数..这样子应该没问题的吧。。但还是跪了。下次有double型的数据即使是整数,可以这样写 int(x+0.5)
阅读更多vim在ACM/ICPC中的使用 Posted on 2014年11月22日 by kuangbin Vim大法好!
应大家的要求,写一篇博客来介绍下vim在ACM中的简单使用。
写本文的目的,只是为了给广大acmer一个入门vim的指导。不喜勿喷! 不想看到的请远离!
阅读更多从放暑假前周sir给我讲了一个用polya计数法和burnside定理做的题目(pku2409)后,突然觉得组合数学挺有意思,然后从那时起到现在几乎都在做这类的题目。
做到现在感觉这类题目的一些基本知识点都差不多有所了解了,水题也刷了不少,但还有很多难题自己实在是做不动,所以准备把这类题目先放一放,然后把前段时间做的水题整理一下(供以后的初学者参考,大牛就不要看了哈,都是水题)。剩下的比较难的题目就慢慢来吧,以后做出来再不上,这个小结会不断地更新。也希望大家有好的题目可以推荐一下,分享一下哈。
感谢:周sir,J_factory和福州大学神牛aekdycoin,大连理工大学神牛czyuan。
不扯了,进入主题:
1.burnside …
阅读更多C. Day at the Beach
time limit per test
2 seconds
memory limit per test
256 megabytes
input
standard input
output
standard output
One day Squidward, Spongebob and Patrick decided to go to the beach. Unfortunately, the weather was bad, so the friends were unable to ride waves. However, they decided to spent their time …
阅读更多B. Spongebob and Joke
time limit per test
2 seconds
memory limit per test
256 megabytes
input
standard input
output
standard output
While Patrick was gone shopping, Spongebob decided to play a little trick on his friend. The naughty Sponge browsed through Patrick’s personal stuff and found a sequence _a_1, _a_2, …
阅读更多

1<span style="color: #008080;"> 1</span> #include <cstdio> 2<span style="color: #008080;"> 2</span> #include <iostream> 3<span style="color: #008080;"> 3</span> #include <cmath> 4<span style="color: …
阅读更多C. A Problem about Polyline
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output
There is a polyline going through points (0, 0) - (x, x) - (2_x_, 0) - (3_x_, x) - (4_x_, 0) - … - (2_kx_, 0) - (2_kx_ + x, x) - ….
We know that the polyline passes …
阅读更多Max Angle
**Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 678 Accepted Submission(s): 238
**Problem Description
Given many points in a plane, two players are playing an interesting game.
Player1 selects one point A as the vertex of an angle. Then player2 selects …
阅读更多Transmitters
**Time Limit:** 1000MS **Memory Limit:** 10000K **Total Submissions:** 4817 **Accepted:** 2576 Description
In a wireless network with multiple transmitters sending on the same frequencies, it is often a requirement that signals don’t overlap, or at least that they don’t …
阅读更多
