Operating Systems

A technician must rename report.txt to report_old.txt in the same directory so that no file named report.txt remains. Which command does this?

Show the answer

Correct answerC. mv report.txt report_old.txt

AWhy not this: Searches report.txt for the text report_old.txt; it renames nothing.

BWhy not this: Deletes both files, destroying the data instead of renaming it.

CWhy this is right: Moves or renames the file, so only report_old.txt exists afterward.

DWhy not this: Copies the file, so report.txt would still remain under the original name.

mv renames a file when the destination is in the same directory, leaving no file under the old name. cp creates a duplicate, so report.txt would still exist.