readTextFile error

how to overcome this error-"‘readTextFile’ is not defined?

Hey @guptadiksha534, readTextFile ( ) function is a function which sir has defined and imported in his code. You can use the open( ) function to read the same file and get a similar output like this :

my_file=open("test1.txt","r")
print(my_file.read())

Hope this helps.
Happy Learning :slight_smile:

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.