Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
分析一下79B以及80多B的代码差别在哪里这题的公式是三次根号下(D^3 - 6V/PI),也就是 cbrt(D*D*D-V/acos(-1)*6),这大概是81B代码的写法 其实acos(0)是PI/2,分子分母都除以2就好了,于是可以简化为 cbrt(D*D*D-V/acos(0)*3),这样就变成了80B 更进一步,其实sin(PI/6)=0.5,那么6V/PI = V/(PI/6) = V/asin(0.5),式子变成了 cbrt(D*D*D-V/asin(0.5)),由于0.5前面的0可以省略,所以最终结果就是 cbrt(D*D*D-V/asin(.5)) Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator