NCAE Mapping Hub
Overview Scoreboard Data Roles Exercised Checklists Lessons Skill Drills Practice Terminal Progress
multiple_choice easy Remember cmd-subst 2 points

Question 6. CSCD240-E1-C

Recommended modern syntax for command substitution?

Work the drill

Answer on paper or in a terminal before revealing the ideal answer.

Ideal answer
B: $(cmd)

Misconception bank

Each row below is a plausible wrong answer, the thinking that produces it, and the remedy that corrects the misconception. These are the foundation of the multiple-choice framing and the targeted feedback a student receives after answering.

A: `cmd`
Misconception. Backticks are legacy; harder to nest.
Remedy. $() is nestable and preferred.
C: ${cmd}
Misconception. ${} is variable expansion, not command substitution.
Remedy. Distinguish ${} vs $().
D: !cmd
Misconception. ! is history expansion.
Remedy. Different mechanism entirely.

Authority mappings

Hover any chip for the mapping justification; click to open the authority record.

DCWF tasks: T0498
KU outcomes: CO-M5-O2

Course-artifact links

Lectures

  • CSCD240-S26-L05. Permissions part 1: ls -l anatomy, rwx, file types

Lab questions

  • CSCD240-S26-LAB5: Use $(date +%F) inside a string. Also demonstrate backticks.

CTF challenges

  • 04 Environment & Patterns: Capture the Output