we can use -t(sort by modification time) option with ls command to list the files according to their modification time.
ls -t | head -1
the above command will display last modified file in current directory.
use below command to edit last modified file.
vim `ls -t | head -1`