For running this script, you must install firstly with following code "pip install pyttsx3"
pyttsx3 is a text-to-speech conversion library in Python. Unlike alternative libraries, it works offline.
Linux installation requirements : If you are on a linux system and if the voice output is not working , then :
Install espeak , ffmpeg and libespeak1 as shown below:
sudo apt update && sudo apt install espeak ffmpeg libespeak1