completely fixed ex26.py - runs without a hitch.