diff --git a/Last Access/Last Access.png b/Last Access/Last Access.png new file mode 100644 index 0000000000..2aedbbb5c2 Binary files /dev/null and b/Last Access/Last Access.png differ diff --git a/Last Access/Last Access.py b/Last Access/Last Access.py new file mode 100644 index 0000000000..3b453c6765 --- /dev/null +++ b/Last Access/Last Access.py @@ -0,0 +1,12 @@ +import os +import time +from os import listdir +from os.path import isfile, join +print("ENTER THE PATH TO FOLDER") +path = input() +files_list = [f for f in listdir(path) if isfile(join(path, f))] +for k in files_list: + print(k) + access_time = os.path.getatime(path +"\\" + k) + local_time = time.ctime(access_time) + print("Last access time(Local time):", local_time) diff --git a/Last Access/README.md b/Last Access/README.md new file mode 100644 index 0000000000..0263ddcfe8 --- /dev/null +++ b/Last Access/README.md @@ -0,0 +1,17 @@ +# Last Access + +It prints out when was the last the file in folder was accessed. + +## Setup instructions + +Just run the script and Enter the path of folder +And press Enter + +## Output + +![Last Access](/Last%20Access/Last%20Access.png) + +## Author(s) + +Vijay Chaurasia +