Logo
(追記) (追記ここまで)

19171번 - Euclid 스페셜 저지다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 512 MB120319610610.861%

문제

Smurfs love to play computer game called SmurfCraft. In this game there are a number of power sources to be harvested. Lazy Smurf must build his new base. He already found the location of three unoccupied power sources, and now wants to build his base in a position that minimizes the total distance to all three of those power sources. This problem wouldn't be difficult (even for Lazy Smurf) if not for the fact that the game is played in 3D. Because Lazy Smurf skipped his geometry classes he doesn't know how to solve this problem. Help him.

입력

There are three input lines, each contains three integers $x, y, z$ ($-10^9 \leq x, y, z \leq 10^9$) -- the coordinates of a power source.

출력

Output the minimum possible total distance to all three of the power sources. Your answer will be accepted if relative or absolute error is less than 10ドル^{-4}$.

제한

예제 입력 1

0 0 0
20 0 0
10 20 0

예제 출력 1

37.320508

힌트

출처

Camp > Petrozavodsk Programming Camp > Winter 2015 > Day 5: U of Wroclaw Contest E번

(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /