포럼
문제 ICPC00311

C. Cardboard Container

설명

-3mm

-15mm

Fidget spinners are so 2017; this years' rage are fidget cubes. A fidget cube is a cube with unit side lengths, which you hold in your hand and fidget with. Kids these days, right?

You work in the planning department for a company that creates and ships fidget cubes. Having done some market analysis, you found that your customers want to receive shipments of exactly \(V\) fidget cubes.

This means you have to design a container that will hold exactly \(V\) fidget cubes. Since fidget cubes are very fragile, you cannot have any empty space in your container. If there is empty space, they might move around, bump into each other and get damaged. Because of this, you decide to ship the fidget cubes in a rectangular cardboard box.

The cost of a cardboard box is proportional to its surface area, costing exactly one unit of money per square unit of surface area. Of course you want to spend as little money as possible. Subject to the above constraints, how much money do you have to spend on a box for \(V\) fidget cubes?

제약
입력 형식

The input contains a single integer, \(1 \leq V \leq 10^6\), the number of fidget cubes for which you need to build a box.

출력 형식

Print the cost of the cheapest rectangular box as specified in the statement.

예제 1
입력
1
출력
6
예제 2
입력
4
출력
16
예제 3
입력
3
출력
14
예제 4
입력
5913
출력
2790
문제 정보

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

출처 ICPC BAPC 2018

평가 및 의견

C. Cardboard Container

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

Log in to rate problems.

개별 의견

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

풀이 제출

C. Cardboard Container

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