Minimal number of steps to get from 0 to n by (a) adding 1 or (b) subtracting 1 or (c) multiplying by 3.

A061295

Minimal number of steps to get from 0 to n by (a) adding 1 or (b) subtracting 1 or (c) multiplying by 3.

Terms

    a(0) =0a(1) =1a(2) =2a(3) =2a(4) =3a(5) =4a(6) =3a(7) =4a(8) =4a(9) =3a(10) =4a(11) =5a(12) =4a(13) =5a(14) =6a(15) =5a(16) =6a(17) =5a(18) =4a(19) =5a(20) =6a(21) =5a(22) =6a(23) =6a(24) =5a(25) =6a(26) =5a(27) =4a(28) =5a(29) =6

External references