|
|
Is test #6 checking something interesting, or is it just precision-test? At least, which solid is used in this test? const long double eps=1e-12; using long double... I see many coders had problems with this test. Please, give me some hint to aviod them. I think there are some problems with presicion, but I don't know how to fix this. Can somebody help me? How do we get the answer 1.78? Which angle do we rotate the star by at every step? My program outputs the following angles: 1.2309594173 0.9654637454 0.6737614519 0.5281218484 0.4721787343 which give the answer 3.8704851972 0.000000000 0.445561254 0.445561254 0.445561254 0.445561254 I think, your mistake that: "Each of the following n lines contains the vector of the attack". It mean, if vector of attack (0,0,-1), attack goes from (0,0,1). Good luck! Edited by author 27.04.2009 17:59 OMG! Thank you very much, now it should be AC. What answer on this test: octahedron 2 -7 -7 -8 0.63 0.22 -0.74 I think that 1.38131 Edited by author 11.11.2008 21:01 My program write 1.38131 too. But I'm think is wrong answer because exists fastest rotation with angle 0.99346. I'm right? It must be 1.38131. At the moment of first shot you don't know the direction of next one, so you can't take it into account. Thanks, I understood that my error was in accuracy Edited by author 12.11.2008 15:54 There are two ways of putting each of Platonic solids (except octahedron) into space according to the statement (with its center at the center of coordinate system, one megagun aimed along Oz in a positive direction and one of adjacent edges in Oxz (that edge can be directed both positively and negatively)). |
|
|