Initial submission.

NameError: global name 'rd' is not defined
Unexpected Nones in output.
My response

Move import to top.
Add 'main' driver to demonstrate.
Still unepected Nones in output.
Miguel corrects my indentation: Unexpected Nones fixed.
Comments & small/large demonstrations.