📅  最后修改于: 2022-03-11 14:46:46.658000             🧑  作者: Mango
pip install PyPDF2
import PyPDF2
pdfFileObject=open(r"F:\fileName.pdf",'rb')
pdfReader = PyPDF2.PdfFileReader(pdfFileObject) //Creating reader obj
print(" No. Of Pages :", pdfReader.numPages)//To know no.of pages