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

32888번 - Consolidating Windows 스페셜 저지다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 (추가 시간 없음) 1024 MB23220218188.293%

문제

In the 19th century, windows were a costly luxury in Delft, as you had to pay tax for every single window in your home. Only the wealthy people could afford more than a few, while many poorer residents bricked up some of their windows to avoid the enormous costs introduced by the new policy.

Not wanting to sacrifice any of the precious sunlight in her home, Corry came up with an ingenious idea: since the tax was based solely on the number of windows and not their size, she decided to install fewer but larger windows instead of many small ones. In each room, Corry had two square windows which she planned to replace by one single, square window to halve the tax. The area of this new window should equal the combined area of the two smaller ones. Given the side lengths of the two smaller windows, what is the side length of the larger window?

입력

The input consists of:

  • One line with two integers $a$ and $b$ (1ドル\leq a, b\leq 10^9$), the side lengths of the two smaller square windows.

출력

Output the side length of a square window that has the same area as the two smaller windows combined.

Your answer should have an absolute or relative error of at most 10ドル^{-8}$.

제한

예제 입력 1

3 4

예제 출력 1

5.0

예제 입력 2

10000000 320912

예제 출력 2

10005147.900543199866

힌트

출처

ICPC > Regionals > Europe > Northwestern European Regional Contest > NWERC 2024 연습 세션 C번

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

출처

대학교 대회

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

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