Back to Freecodecamp

Step 2

curriculum/challenges/english/blocks/learn-recursion-by-solving-the-tower-of-hanoi-puzzle/64de1469fccce61940f498c4.md

latest965 B
Original Source

--description--

The rods dictionary will represent the three rods with their disks. Give it the strings 'A', 'B', and 'C' as keys and set each of them to an empty list.

--hints--

Your rods dictionary should have an 'A' key.

js
({ test: () => assert(runPython(`'A' in rods`)) })

rods['A'] should be an empty list.

js
({ test: () => assert(runPython(`
    rods['A'] == []
  `))
})

Your rods dictionary should have a 'B' key.

js
({ test: () => assert(runPython(`'B' in rods`)) })

rods['B'] should be an empty list.

js
({ test: () => assert(runPython(`
    rods['B'] == []
  `))
})

Your rods dictionary should have a 'C' key.

js
({ test: () => assert(runPython(`'C' in rods`)) })

rods['C'] should be an empty list.

js
({ test: () => assert(runPython(`
    rods['C'] == []
  `))
})

--seed--

--seed-contents--

py
--fcc-editable-region--
rods = {}
--fcc-editable-region--