Reading files:To read a file you should know this functions: open(“filename”,”r”) and filename.read()The first one is used to open a file, read it and pass that information to a variable ( if you want) or to simply work with it directly.The second one …