Загрузка [MathJax]/jax/output/HTML-CSS/fonts/TeX/fontdata.js

printРабочее место участника

printЗадачи

824. Play with Cubes

Ограничения: время – 1s/2s, память – 64MiB Ввод: input.txt или стандартный ввод Вывод: output.txt или стандартный вывод copy
Послать решение Blockly Посылки Темы Где Обсудить (1)

The first line of the input file contains a single integer N (1 ) representing the number of unit cubes.
Write to the output file minimal number of unit cubes which need adding to N cubes so it must be possible to assemble a entire cube from all unit cubes.

Sample Input

23

Sample Output

4
loading