Python FTP get the most recent file by date

I am using ftplib to connect to an ftp site. I want to get the most recently uploaded file and download it. I am able to connect to the ftp server and list the files, I also have put them in a list and got the datefield converted. Is there any function/module which can get the recent date and output the whole line from the list?

Checking if object on FTP server is file or directory using Python and ftplib

Using Python and ftplib, I’m writing a generic function to check whether the items in an FTP directory are either files or directories. Since using the MLSD function might not necessarily work with all servers ( one of my use cases does not provide for it ) I have resorted to this effective but crude manner of determining it, by attempting to change directory to the object and if the object is a file, an exception is raised and the file type is set accordingly.