Copying text files to a floppy disk in DOS Which single command copies all files with the .TXT extension from the current drive and directory to drive A?

Difficulty: Easy

Correct Answer: COPY *.TXT A:

Explanation:


Introduction / Context:
Wildcards provide fast, flexible file operations in DOS. When moving groups of files to removable media, the COPY command combined with the asterisk pattern simplifies backups and transfers. Using the correct source–destination order prevents overwriting the wrong location.



Given Data / Assumptions:

  • You are in the source directory containing .TXT files.
  • Drive A: is present and writable (for example, a floppy disk).
  • Goal: copy all .TXT files from here to A: in one step.


Concept / Approach:

The syntax is COPY source destination. A wildcard pattern like *.TXT means “all files ending in .TXT” in the current directory. The destination is specified as a drive or path. The command does not delete originals; it simply duplicates them to the target.



Step-by-Step Solution:

Insert a formatted disk in drive A:.At the prompt, type COPY *.TXT A: and press Enter.Observe the “n file(s) copied” message indicating success.Run DIR A: to verify the new files are present.Label the floppy and store it securely if used as a backup.


Verification / Alternative check:

Create a new text file locally and repeat the COPY command; confirm it appears on A:. This validates the pattern and the source–destination order.



Why Other Options Are Wrong:

a: Reverses source and destination; it attempts to copy from A: to the current directory.

c: Copies to C:, not A:.

d: Copies multiple files into a single file named ALL.TXT, which is not the goal.

e: Not applicable because option b is correct.



Common Pitfalls:

Forgetting to include the colon after drive letters; insufficient disk space on A:; unintentionally overwriting existing files on the destination without confirmation.



Final Answer:

COPY *.TXT A:

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion