While working with MS-DOS, which command is used to rename a file named file1.doc to file2.doc from a different directory called dir1? A. Ren2.doc \dir\file1.doc B. Ren file1.doc file2.doc C. Ren .doc\dir\.doc D. Ren \dir1\file1.doc file2.doc

Ren2.doc dir ile1.doc
Ren file1.doc file2.doc
Ren .docdir.doc
Ren dir1 ile1.doc file2.doc

The correct answer is D.

The ren command is used to rename a file. The syntax is ren oldname newname. In this case, the old name is file1.doc and the new name is file2.doc. The file is located in the directory dir1. Therefore, the command to rename the file is ren \dir1\file1.doc file2.doc.

Option A is incorrect because it does not specify the directory where the file is located.

Option B is incorrect because it does not rename the file. It simply creates a new file named file2.doc.

Option C is incorrect because it does not specify the new name of the file.

I hope this helps!