nerdexam
LPI

101-400 · Question #407

Which of the following examples for Bash file globbing matches a file named root-can-do-this.txt when used in the directory holding that file? (Choose three correct answers.)

The correct answer is A. root*can?do-this.{txt,odt} B. r[oOoO]t-can-do*.txt C. {root,user,admin}-can-??-this.txt. See the full explanation below for the reasoning.

Question

Which of the following examples for Bash file globbing matches a file named root-can-do-this.txt when used in the directory holding that file? (Choose three correct answers.)

Options

  • Aroot*can?do-this.{txt,odt}
  • Br[oOoO]t-can-do*.txt
  • C{root,user,admin}-can-??-this.txt
  • Drootcando??this.txt
  • Eroot***{can,may}-do-this.[tT][xX][tT]

How the community answered

(23 responses)
  • A
    74% (17)
  • D
    9% (2)
  • E
    17% (4)

Community Discussion

No community discussion yet for this question.

Full 101-400 Practice