- 博客(9)
- 收藏
- 关注
转载 Game of Taking Stones HDU - 5973 (威佐夫博弈+Java的高精度)
Game of Taking Stones HDU - 5973 Two people face two piles of stones and make a game. They take turns to take stones. As game rules, there are two different methods of taking stones: One scheme is...
2018-10-23 21:12:46 193
原创 Lucky Man ZOJ - 4005 (JAVA大整数+牛顿迭代法开根)
Lucky Man ZOJ - 4005 BaoBao is keen on collection. Recently he is abandoning himself to Kantai Collection, especially to collecting cute girls, known as "Fleet Girls". There are various types ...
2018-10-22 21:28:48 486
原创 Happy Sequence ZOJ - 4011 (dp)
Happy Sequence ZOJ - 4011 A sequence of integers () is called a happy sequence if each number divides (without a remainder) the next number in the sequence. More formally, we can say for all , ...
2018-10-21 20:40:24 165 1
原创 不要62 HDU - 2089
不要62 HDU - 2089 杭州人称那些傻乎乎粘嗒嗒的人为62(音:laoer)。 杭州交通管理局经常会扩充一些的士车牌照,新近出来一个好消息,以后上牌照,不再含有不吉利的数字了,这样一来,就可以消除个别的士司机和乘客的心理障碍,更安全地服务大众。 不吉利的数字为所有含有4或62的号码。例如: 62315 73418 88914 都属于不吉利号码。但是,61152虽然含有...
2018-10-15 21:51:07 143
原创 What day is that day? ZOJ - 3785
What day is that day? ZOJ - 3785 It's Saturday today, what day is it after 11 + 22 + 33 + ... + NNdays? Input There are multiple test cases. The first line of input contains an integer T indicat...
2018-10-14 21:39:07 196
原创 A/B HDU - 1576
A/B HDU - 1576 要求(A/B)%9973,但由于A很大,我们只给出n(n=A%9973)(我们给定的A必能被B整除,且gcd(B,9973) = 1)。 Input 数据的第一行是一个T,表示有T组数据。 每组数据有两个数n(0 <= n < 9973)和B(1 <= B <= 10^9)。 Output 对应每组数据输出(A/B)%9973...
2018-10-09 22:00:18 170
原创 大菲波数 HDU - 1715
Fibonacci数列,定义如下: f(1)=f(2)=1 f(n)=f(n-1)+f(n-2) n>=3。 计算第n项Fibonacci数值。 Input 输入第一行为一个整数N,接下来N行为整数Pi(1<=Pi<=1000)。 Output 输出为N行,每行为对应的f(Pi)。 Sample Input 5 1 2 3 4 5 Sample Out...
2018-10-09 21:35:15 145
原创 大数加法 51Nod - 1005
大数加法 51Nod - 1005 给出2个大整数A,B,计算A+B的结果。 Input 第1行:大数A 第2行:大数B (A,B的长度 <= 10000 需注意:A B有可能为负数) Output 输出A + B Sample Input 68932147586 468711654886 Sample Output 537643802472 import...
2018-10-09 21:15:03 172
原创 a==b? java
A == B ? HDU - 2054 Give you two numbers A and B, if A is equal to B, you should print "YES", or print "NO". Input each test case contains two numbers A and B. Output for each case, if A is e...
2018-10-09 20:43:39 615
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人