Which pathlib method reads a whole text file in Python?
Correct answer
A. read_text()
9 views
A. read_text()
9 views
Path.read_text() returns the file's content as a string.
Asked in: Python Interview Standard Library
https://docs.python.org/3/library/index.htmlNot sure why the answer is A? Ask here and get an explanation.