CompTIA
LX0-104 · Question #3
LX0-104 Question #3: Real Exam Question with Answer & Explanation
The correct answer is A: mydate="$(date)". See the full explanation below for the reasoning.
Question
Which of the following commands puts the output of the command date into the shell variable mydate?
Options
- Amydate="$(date)"
- Bmydate="exec date"
- Cmydate="$((date))"
- Dmydate="date"
- Emydate="${date}"
Community Discussion
No community discussion yet for this question.