随笔分类 -  UVA

http://uva.onlinejudge.org
摘要:公式:a1 = n * a0 / (n + 1) + an+1 / (n + 1) + ∑∑ci题目: Simple calculations 1 Normal 1 8 5 1996-08-26T09:19:00Z 1996-08-26T18:32:00Z 1 95 544 4 1 668 9.2812 Simple calculations The ProblemThere is a sequence ofn+2 elements a0, a1,…, an+1(n <= 3000; -1000 <=ai1000). It is known th... 阅读全文
posted @ 2013-03-04 11:24 上白泽慧音 阅读(224) 评论(0) 推荐(0)
摘要:很简单的题~题目:Problem G Saman Arash Rahimi 3 81 2005-11-07T20:17:00Z 2005-11-07T20:17:00Z 1 275 1569 Home 13 3 1841 11.5606 Clean 6 pt 2 2 false false false MicrosoftInternetExplorer4 Problem GBig ChocolateMohammad has recently visited Switzerland. A... 阅读全文
posted @ 2013-03-04 09:41 上白泽慧音 阅读(382) 评论(0) 推荐(0)
摘要:第一次TLE了,想到了取对数的方法,但是纠结 2^x-1 后面的 -1 一直保留所以计算超时了。后来实验了一两次,发现 x = 4 的时候 3! = 6 < 2^x-1 < 4!=15 跨度大于 1 了,以后更大,所以 -1 完全可以略去。题目: Problem B: Factstone BenchmarkAmtel has announced that it will release a 128-bit computer chip by 2010, a 256-bit computer by 2020, and so on, continuing its strategy of 阅读全文
posted @ 2013-03-03 23:26 上白泽慧音 阅读(236) 评论(0) 推荐(0)
摘要:数据用long long题目: Problem J - Regionals 2001 Warmup Contest Shahriar Manzoor Administrator 66 234 2001-07-19T02:33:00Z 2000-12-04T12:45:00Z 2001-08-29T15:05:00Z 2 254 1448 CSE, BUET 12 2 1778 9.2720 0 0 Problem J(2/3/4)-D Sqr/Rects/Cubes/Boxes?Input: st... 阅读全文
posted @ 2013-03-03 16:25 上白泽慧音 阅读(190) 评论(0) 推荐(0)
摘要:忘了打空行了,做的时候想起了高中的数学老师 TAT题目: Problem BProblem BQuotient PolynomialTime Limit2 SecondsA polynomial of degree n can be expressed asIf k is any integer then we can write:Here q(x) is called the quotient polynomial of p(x) of degree (n-1) and r is any integer which is called the remainder.For example, i 阅读全文
posted @ 2013-03-03 15:33 上白泽慧音 阅读(302) 评论(0) 推荐(0)
摘要:写的忘了一个问题,整除和余数。题目: Searching for Nessy Searching for Nessy The Loch Ness Monsteris a mysterious and unidentified animal said to inhabit Loch Ness, a large deep freshwaterloch near the cityof Inverness in northern Scotland. Nessie is usually categorized as a type oflake monster.http://en.wikipedia.or 阅读全文
posted @ 2013-03-02 21:50 上白泽慧音 阅读(231) 评论(0) 推荐(0)
摘要:刚开始有点被书“误导”了,上来就想用一下公式,结果连简单的排列组合都忘了。数据结果很大要用long long题目: How Many Points of Intersection?We have two rows. There are a dots on the top row and b dots on the bottom row. We draw line segments connecting every dot on the top row with every dot on the bottom row. The dots are arranged in such a way t. 阅读全文
posted @ 2013-03-02 20:25 上白泽慧音 阅读(266) 评论(0) 推荐(0)
摘要:题目不太好懂,看了别人的翻译。大概意思就是,球形表面积增加量比上原表面积,其实就是n/4*100%题目: Administrator SHAHRIAR MANZOOR 180 1629 2002-10-25T13:01:00Z 2001-06-30T12:55:00Z 2003-01-10T18:14:00Z 2 337 1922 BUET 16 3 2360 9.2720 Print BestFit MicrosoftInternetExplorer4 Clean Problem HThe Land of JusticeInput: s... 阅读全文
posted @ 2013-03-02 19:26 上白泽慧音 阅读(291) 评论(0) 推荐(0)
摘要:找规律可以发现一个数列 (0),1,2,4,6,9,12,16,20....分别是1步,2步,3步,4步....的最大距离。然后把x-y锁定到一个区间就行了。注意距离为0的时候走0步。题目: Steps StepsOne steps through integer points of the straight line. The length of a step must be nonnegative and can be by one bigger than, equal to, or by one smaller than the length of the previous step.W 阅读全文
posted @ 2013-03-02 18:40 上白泽慧音 阅读(282) 评论(0) 推荐(0)
摘要:注意:1. 判定成功的时候不要减去滑下的距离2.上升距离为负时要保持为0题目: The SnailA snail is at the bottom of a 6-foot well and wants to climb to the top. The snail can climb 3 feet while the sun is up, but slides down 1 foot at night while sleeping. The snail has a fatigue factor of 10%, which means that on each successive day th. 阅读全文
posted @ 2013-03-02 18:15 上白泽慧音 阅读(218) 评论(0) 推荐(0)
摘要:精度控制+查找题目:The Cat in the HatThe Cat in the HatBackground(An homage to Theodore Seuss Geisel) The Cat in the Hat is a nasty creature, But the striped hat he is wearing has a rather nifty feature.With one flick of his wrist he pops his top off.Do you know what's inside that Cat's hat? A bunch 阅读全文
posted @ 2013-03-02 15:15 上白泽慧音 阅读(568) 评论(0) 推荐(0)
摘要:没难度~题目: Box of BricksLittle Bob likes playing with his box of bricks. He puts the bricks one upon another and builds stacks of different height. ``Look, I've built a wall!'', he tells his older sister Alice. ``Nah, you should make all stacks the same height. Then you would have a real wa 阅读全文
posted @ 2013-03-02 11:18 上白泽慧音 阅读(219) 评论(0) 推荐(0)
摘要:算法需要自己猜,参考了题解。题目: The ? 1 ? 2 ? ... ? n = k problemTheproblemGiven the following formula, one can set operators '+' or '-' instead of each '?', in order to obtain a given k? 1 ? 2 ? ... ? n = kFor example: to obtain k = 12 , the expression to be used will be: - 1 + 2 + 3 + 4 阅读全文
posted @ 2013-03-02 10:56 上白泽慧音 阅读(252) 评论(0) 推荐(0)
摘要:没啥说的,题目没看懂,但是数据很一般,很好AC。题目: Secret Research Secret ResearchAt a certain laboratory results of secret research are thoroughly encrypted. A result of a single experiment is stored as an information of its completion: `positive result',`negative result',`experiment failed' or`experiment not 阅读全文
posted @ 2013-03-02 10:22 上白泽慧音 阅读(300) 评论(0) 推荐(0)
摘要:WA的原因竟然因为....竟然因为...把TRUE拼成TURE了...英死早,囧...题目:Cube paintingCube paintingWe have a machine for painting cubes. It is supplied with three different colors: blue, red and green. Each face of the cube gets one of these colors. The cube's faces are numbered as in Figure 1.Figure 1.Since a cube has 6 阅读全文
posted @ 2013-03-01 22:54 上白泽慧音 阅读(1108) 评论(0) 推荐(0)
摘要:开学了,从现在开始吧~题目: Problem A.Ant on a Chessboard Background One day, an ant calledAlice came to an M*M chessboard. She wanted to go around all the grids. So shebegan to walk along the chessboard according to this way: (you can assume thather speed is one grid per second) At the first second,Alice was... 阅读全文
posted @ 2013-03-01 14:00 上白泽慧音 阅读(169) 评论(0) 推荐(0)
摘要:本来坐等WA的,十行的代码竟然没出精度问题。题目: Power of CryptographyPower of CryptographyBackgroundCurrent work in cryptography involves (among other things) large prime numbers and computing powers of numbers modulo functions of these primes. Work in this area has resulted in the practical use of results from number th 阅读全文
posted @ 2013-02-20 17:34 上白泽慧音 阅读(146) 评论(0) 推荐(0)
摘要:虽然是sorting的压轴,但是比起前面真心水题。这个专题结合前面string的很多,排序相对简单了,qsort基本解决。题目: The Mad NumerologistNumerology is a science that is used by many people to find out a mans personality, sole purpose of life, desires to experience etc. Some calculations of numerology are very complex, while others are quite simple. Y 阅读全文
posted @ 2013-02-20 16:34 上白泽慧音 阅读(526) 评论(0) 推荐(0)
摘要:做题晕了,两处笔误没看见,还漏了一个排序条件,真不爽。对了,按字典排序不区分大小写,题目又没说明白。题目: Football (aka Soccer)Problem A: Football (aka Soccer)The ProblemFootball the most popular sport in the world (americans insist to call it "Soccer",but we will call it "Football"). As everyone knows, Brasil is the country that 阅读全文
posted @ 2013-02-19 21:49 上白泽慧音 阅读(491) 评论(0) 推荐(0)
摘要:这题真的是一把辛酸泪啊,好复杂,做了两天。个人算法比较弱啊,看代码量就知道了。先提取关键字,然后储存题目下标。把关键字排序,储存题目下标的数组排序,最后输出来。脑子快做炸了,但是最后还是AC了。题目: Searching QuicklySearching QuicklyBackgroundSearching and sorting are part of the theory and practice of computer science. For example, binary search provides a good example of an easy-to-understand 阅读全文
posted @ 2013-02-19 16:19 上白泽慧音 阅读(356) 评论(0) 推荐(0)