Skip to content

Challenge 234: Building Integers

In this problem, the following are allowed operations on positive integers.

  • add a zero at the end of the number;
  • add a two at the end of the number;
  • add a seven at the end of the number;
  • divide the number by 2.

Show that, starting from 1, every positive integer can be constructed by using a sequence of allowed operations.

Connect with