Update printWord.py

Fixed function