포럼
문제 ICPC00279

G. Grazed Grains

스페셜 저지 — 출력을 사용자 정의 프로그램으로 검사하므로 여러 정답이 인정될 수 있습니다.
설명

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
출력
3.1415926535
예제 2
입력
4
0 0 2
1 0 1
2 2 2
10 10 1
출력
25.991148
문제 정보

생성자가 기록되지 않았습니다.

출처 ICPC NCPC 2021

평가 및 의견

G. Grazed Grains

개요
출제자 난이도 Unrated 레이팅 미적용 의견 0 / 1 공개 집계 (커뮤니티 난이도, 주요 주제, 품질)는 의견이 충분히 모이면 공개됩니다.

Log in to rate problems.

개별 의견

아직 의견이 없습니다. 자격이 된다면 위 양식에서 가장 먼저 평가해 보세요.

풀이 제출

G. Grazed Grains

게스트로 둘러보고 있습니다. 로그인하면 풀이를 제출하고 진행 상황을 확인할 수 있습니다. 로그인하고 제출하기
공개
C++20 Tab 들여쓰기 · Ctrl+/ 주석 토글 · Enter 자동 들여쓰기
1 1 1 0 공백: 4 · UTF-8