Which command is used to display all the files having the (.exe) extension but different filename? A. Dir filename.* B. Dir filename.ext C. Dir *.sys D. Dir *.exe

Dir filename.*
Dir filename.ext
Dir *.sys
Dir *.exe

The correct answer is D. Dir *.exe.

The Dir command is used to list the files in a directory. The asterisk () is a wildcard character that matches any number of characters. So, the command Dir .exe will list all the files in the current directory that have the .exe extension.

The other options are incorrect because they do not use the asterisk () wildcard character. Option A, Dir filename., would list all the files in the current directory that have the filename “filename”. Option B, Dir filename.ext, would list all the files in the current directory that have the extension “ext”. Option C, Dir *.sys, would list all the files in the current directory that have the extension “sys”.