How to record the starting and ending date and time at the beginning and ending of the file accordingly?
Your exact problem is unclear, but I will address an inferred question “How to time things in Python?” Hopefully you can use the guides to address your issue.
It is common to see time recorded in the following idiom:
start = time.time() # your code end = time.time() print("Duration: ", end - start)
You can get varying specificity depending on which
time object you use, e.g.
Thank you, This is exactly questioned about the project am working on:
"You also need to record the starting and ending date and time at the beginning and ending of the file
accordingly. It should also show the total time it took in the port scanning process
Let me know if you need further information.
Am using the Socket library.
While I can (just barely) understand your problem a bit more, you know it more than I do. More critically, this sounds like an assignment, so I won’t give a solution. However, the comment and guides I’ve mentioned should adequately equip you to solve this and many other time-related problems. Again, start with
datetime libraries. I’m happy to see what you come up with
Thank you, I was able to figure it out… thank you so much !