Minimum Steps to One Problem

Understand the problem and build a brute force solution.

We'll cover the following...

Problem statement

On a positive integer, you can perform any one of the following 3 steps:

1. Subtract 1 from it.

2. If it is divisible by 2, divide by 2.

3. If it is divisible by 3, divide by 3.

Given a positive integer n, find the minimum number of steps that takes n to 1.

Wait a ...