Which flag should be added to the rm command to prompt the user with a question mark before deleting each file?

Basic of linux unix MCQs for PPSC, FPSC, NTS, and Pakistan government job tests. Select an option below, then read the explanation.

PPSCFPSCNTSPakistan govt jobs
Subject
Basic of linux unixsoftware-engineering-mcqs › basic-of-linux-unix
Published
6 Apr 2019
Last updated
28 May 2026

Browse all Basic of linux unix MCQs

Choose the correct answer

Explanation

The '-i' option enables interactive mode in the rm command, causing it to ask for confirmation with a '?' before deleting each file. Other options like '-r' are for recursive deletion, '-x' is not a valid rm option, and '-1' is unrelated.

PakQuizHub — free MCQs and past papers for Pakistan government job tests. Content is for educational practice only.