Session Review

Session ID: 129
Mode: objective
Status: in_progress
Score: 0%

Filter: All | Incorrect | Flagged | Unanswered

Current filter: Unanswered

Back to Session

Question 1 (103.7-020 / short_answer)

Name the two POSIX forms of regular expressions mentioned in the lesson.

Status: Unanswered

Your Answer:

Accepted Answer(s):
basic regular expressions and extended regular expressions
basic and extended regular expressions

Explanation:
The lesson explains that POSIX defines two forms: basic regular expressions and extended regular expressions [1].

Question 2 (103.7-010 / multiple_choice)

Which grep option selects every line except those containing matches?

Status: Unanswered

Your Answer:

Options:

Explanation:
The lesson lists -v or --invert-match as the option to select every line except those containing matches [1].

Question 3 (103.7-008 / multiple_choice)

Which grep option displays only the total count of matching lines instead of the lines themselves?

Status: Unanswered

Your Answer:

Options:

Explanation:
The lesson lists -c or --count as the option to display only the total count of matches [1].

Question 4 (103.7-021 / short_answer)

Which grep option makes searches case-insensitive?

Status: Unanswered

Your Answer:

Accepted Answer(s):
-i
--ignore-case
grep -i

Explanation:
The lesson lists -i or --ignore-case [1].

Question 5 (103.7-007 / multiple_choice)

Which grep option makes the search case-insensitive?

Status: Unanswered

Your Answer:

Options:

Explanation:
The lesson lists -i or --ignore-case as the option to turn the search case-insensitive [1].

Question 6 (103.7-028 / command_line)

Enter the egrep command that lists only .org or .com domains from domains.txt.

Status: Unanswered

Your Answer:

Accepted Answer(s):
egrep ".org$|.com$" domains.txt

Explanation:
The guided exercise answer gives this exact command [1].

Question 7 (103.7-001 / multiple_choice)

What does the dot (.) atom match in a regular expression?

Status: Unanswered

Your Answer:

Options:

Explanation:
The dot atom matches any character [1].

Question 8 (103.7-023 / short_answer)

Which grep option selects all lines except matching ones?

Status: Unanswered

Your Answer:

Accepted Answer(s):
-v
--invert-match
grep -v

Explanation:
The lesson lists -v or --invert-match [1].

Question 9 (103.7-016 / multiple_choice)

How can egrep be used to list only .org or .com domains from domains.txt?

Status: Unanswered

Your Answer:

Options:

Explanation:
The guided exercise answer gives egrep ".org$|.com$" domains.txt [1].

Question 10 (103.7-029 / command_line)

Enter the grep command that counts disks named /dev/sda or /dev/sdb from the output of fdisk -l.

Status: Unanswered

Your Answer:

Accepted Answer(s):
fdisk -l | grep '^Disk /dev/sd[ab]' -c

Explanation:
The lesson gives fdisk -l | grep '^Disk /dev/sd[ab]' -c as an example [1].