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

23271번 - Grazed Grains 스페셜 저지다국어

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

문제

This year, there have been unusually many UFO sightings reported. Nobody knows if they are caused by optical illusions, weather phenomena, or secret technology being tested by foreign powers (terrestrial or not). UFO enthusiasts across the world rejoice, and speculations run wild. But someone who is not impressed is the farmer Celeste. Her large grain field has repeatedly been used as a landing site by the UFOs, destroying her crops. Celeste would like to bring whoever is responsible to justice, but before she can do so she must assess the damage caused by the unidentified flying offenders.

In total $n$ circular UFOs have landed in Celeste's field. The $i$th one left a crop circle which destroyed all crops within radius $r_i$ of the point $x_i, y_i$. The field is very large, so you can assume that it extends infinitely in all directions. Your task is to estimate the total area of crops destroyed by the UFOs. Celeste only needs a rough estimate of the true answer, and your answer will be counted as correct if its relative error is less than 10ドル\%$.

입력

The first line of input contains one integer $n$ (1ドル \leq n \leq 10$), the number of UFOs. Then follow $n$ lines, the $i$th of which contains the three integers $x_i,ドル $y_i,ドル and $r_i$ (0ドル \leq x_i, y_i \leq 10,ドル 1ドル \leq r_i \leq 10$), describing the crop circle left by the $i$th UFO.

출력

Output the total area covered by the crop circles in the input, with a relative error of at most 1ドル/10$.

제한

예제 입력 1

1
0 0 1

예제 출력 1

3.1415926535

예제 입력 2

4
0 0 2
1 0 1
2 2 2
10 10 1

예제 출력 2

25.991148

힌트

출처

ICPC > Regionals > Europe > Northwestern European Regional Contest > Nordic Collegiate Programming Contest > NCPC 2021 G번

  • 문제를 만든 사람: Nils Gustafsson
(追記) (追記ここまで)

출처

대학교 대회

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

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