2010.04.22 第四次系列讲座
DESCRIPTION
2010.04.22 第四次系列讲座. 程宇 2008-2009(Seed) Jakarta 2 nd Chengdu 13 th 2009-2010 Assistant Coach Hefei , Hsinchu , Tokyo , World Final in Harbin bbsID: chycharlie [email protected]. Thinking for Fun (Part 1). SJTU ICPC Team Cheng Yu. Contents. - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/1.jpg)
2010.04.22 第四次系列讲座
![Page 2: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/2.jpg)
程宇
2008-2009 (Seed)Jakarta 2nd
Chengdu 13th
2009-2010Assistant CoachHefei, Hsinchu, Tokyo, World Final in Harbin
bbsID: [email protected]
![Page 3: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/3.jpg)
Thinking for Fun(Part 1)
SJTU ICPC TeamCheng Yu
![Page 4: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/4.jpg)
Contents
• ICPC Team Selection Paper Based TestYear 2004, 2005, 2006 and 2009
• Mathematics / Riddles
![Page 5: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/5.jpg)
Some fact about Stage 1
• Problems in English
• Less important than computer based test
• Last year:2 hours10 problems about maths & algorithm
![Page 6: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/6.jpg)
Let’s start now!
Using your Head is Permitted
![Page 7: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/7.jpg)
Loop mod 10:
0 1 5 62 → 4 → 8 → 63 → 9 → 7 → 14 → 67 → 9 → 3 → 18 → 4 → 2 → 69 → 1
2004 (2)
Loop mod 2:
0 1
![Page 8: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/8.jpg)
Module
(a * b) % m = (a % m) * (b % m)
p is a prime:Wilson: (p-1)! ≡ -1 (mod p)Fermat: ap-1 ≡ 1 (mod p)
![Page 9: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/9.jpg)
2004 (11)
a
cb a + 4b + 4c = 1
a + 2b = PI/2 – 1b + 2c = 1 – PI/4
![Page 10: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/10.jpg)
2004 (15)
PI2/6 = S + ¼ * PI2/6
![Page 11: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/11.jpg)
2004 (16)
x1 + x2 + x3 = 2C(4,2) = 6
![Page 12: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/12.jpg)
2005 (2)
![Page 13: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/13.jpg)
2005 (6)
![Page 14: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/14.jpg)
1+2+3+4 = 5+6+7+8
12 个小球中有一个质量与众不同,但不知是轻是重能否用无砝码的天平在三次内找出来
1+2+3+4 > 5+6+7+8 9 + 10 = 1 + 11
1+5+6 > 2+8+9 1 重 , 8 轻
出现在不等号异侧的球一定是好的
9 + 10 > 1 + 111+5+6 = 2+8+9 34 重 , 7 轻
1+5+6 < 2+8+9 2 重 , 56 轻
2005 (7)
![Page 15: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/15.jpg)
Odd Ball Problem
13 balls
Upper Bound given by informatics
Recent MSRA interview question1000 boxes, each contain 12 balls1 heavier ball in every box121000 = 3k → k = 2262
![Page 16: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/16.jpg)
Peter’s home is located (0, 0), and the school is located (9, 9). He can only walk up/right, and cannot pass (2,7),(5,3),(7,6).Can you tell me how many routes are there from peter’s home to school?
2009 (1)
1.Add by calculator
2. Sum = AE – ABE – ACE –
ADE + ACDE
![Page 17: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/17.jpg)
A k-digit number n is called square-repetition if and only if the last k-digit of n2 is still n.For example, the last two digit of 625(252) is 25, so 25 is square-repetition.List all the 4-digit square-repetition number.
2009 (3)
9376
![Page 18: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/18.jpg)
Strategy of Paper Based Test
• Try to read all the problem first.
• Skip the problem that is too hard.
• Think more, write less. Write what is important.
![Page 19: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/19.jpg)
Let’s continuewith some riddles!
Using your Head is still Permitted
![Page 20: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/20.jpg)
直线带球时,在哪里拥有最大的射门角度?
Use a circle
![Page 21: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/21.jpg)
一架飞机先向北飞 1000 km ,又向东飞行了 1000 km ,最后向南飞 1000 km ,发现回到了起点,请问它是在哪里起飞的?
南极
Think twice
![Page 22: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/22.jpg)
N 个平面最多能把空间分为多少个部分?
N 条直线最多能把平面分为多少个部分?
( 1) ( ) 1L n L n n
( 1) ( ) ( )P n P n L n
V + F = E + 2
![Page 23: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/23.jpg)
1 1[ ( )]n n Nf f f f
只要能从起点遍历所有自然数即可
算术几何平均不等式( ) (2 )f n f n( ) ( 1)f n f n
Mathematical Induction
![Page 24: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/24.jpg)
Riddles
拿全四种花色的期望
正八面体最近距离
![Page 25: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/25.jpg)
A group of N students is taking an IQ test. A professor will write a random number from 1 to N on everyone’s back. Notice that two students may have the same number. One can see everybody else’s number, but not his own. They are not allowed to communicate in any way.They will then go to the professor’s room one by one, try to guess the number wrote on their own back. If anyone answers correctly, they all get to pass, otherwise they fail.a). Start with N = 2b). Try to solve N = 16
2009 (8)
![Page 26: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/26.jpg)
Riddles
拿全四种花色的期望
正八面体最近距离
2n 个人,开箱子越狱
![Page 27: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/27.jpg)
http://www.matrix67.com/blog
![Page 28: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/28.jpg)
给一个瞎子 52 张扑克牌,并告诉他里面恰好有 10 张牌是正面朝上的。要求这个瞎子把牌分成两堆,使得每堆牌里正面朝上的牌的张数一样多。瞎子应该怎么做?
一个环形轨道上有 n 个加油站,所有加油站的油量总和正好够车跑一圈。证明,总能找到其中一个加油站,使得初始时油箱为空的汽车从这里出发,能够顺利环行一 圈回到起点。
Riddles: blog/archives/2671
![Page 29: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/29.jpg)
如何用一枚硬币等概率地产生一个 1 到 3 之间的随机整数?
考虑一个 n*n 的棋盘,把有公共边的两个格子叫做相邻的格子。初始时,有些格子里有病毒。每一秒钟后,只要一个格子至少有两个相邻格子染上了病毒,那么他 自己也会被感染。为了让所有的格子都被感染,初始时最少需要有几个带病毒的格子?给出一种方案并证明最优性。
Riddles: blog/archives/2671
![Page 30: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/30.jpg)
多边形一定有内接正三角形
![Page 31: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/31.jpg)
n * 2n-1 = ∑C(n,k) * k (k=1..n)
Combinations
![Page 32: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/32.jpg)
Pick Theorem
![Page 33: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/33.jpg)
Sierpinski Triangle
![Page 34: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/34.jpg)
Sphere of Love
![Page 35: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/35.jpg)
Calculate the mass of a circleρ(x,y) = ln(x2 + y2)
Open Problem
ANS = S * (ρ @ center)
![Page 36: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/36.jpg)
Something about ICPC
• Using your head, or it will get rusty.
• There will be sacrifices, but I promise you, the experience is worth it.
• Learn teamwork & make friends.
![Page 37: 2010.04.22 第四次系列讲座](https://reader033.vdocuments.net/reader033/viewer/2022061410/568149ee550346895db71fd8/html5/thumbnails/37.jpg)
Thank You!