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

35019번 - Bounding Boxes 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
2 초 2048 MB242419100.000%

문제

ICPC is considering sending out contest souvenirs via a delivery service. The delivery service provides multiple types of packing boxes, each shaped as a rectangular parallelepiped.

Unfortunately, there is no way to know which packing box type will be available on the shipping day, so ICPC needs to choose a souvenir box size that fits inside every packing box.

According to the shipment rules, the souvenir box must also be a rectangular parallelepiped. When placed inside a packing box, the souvenir box may be rotated, but its sides must remain parallel to the sides of the packing box. Extra space is not an issue, as it will be filled with plastic wrap.

Help ICPC determine the maximum possible volume of a souvenir box that fits inside all of the packing boxes.

입력

The first line contains a single integer $n,ドル denoting the number of packing box types provided by the delivery service (1ドル \le n \le 1000$).

The $i$-th of the following $n$ lines contains three integers $w_i,ドル $h_i,ドル and $d_i,ドル denoting the width, height, and depth of the $i$-th packing box (1ドル \le w_i, h_i, d_i \le 1000$).

출력

Print the largest possible volume of a souvenir box that fits inside all of the packing boxes. Remember that the souvenir box can be rotated, as long as its sides remain parallel to the sides of the packing box.

제한

예제 입력 1

3
6 5 6
2 10 10
3 8 4

예제 출력 1

48

노트

In the example, the largest souvenir box that fits in each of the packing boxes has dimensions 2ドル \times 4 \times 6$. It fits in the first two packing boxes without rotation, and it can be rotated to become 2ドル \times 6 \times 4$ to fit in the third packing box.

출처

ICPC > Regionals > Northern Eurasia > Northwestern Russia Regional Contest > ICPC 2025-2026 Northwestern Russia Regional Contest B번

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

출처

대학교 대회

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

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