Which of the following commands puts the output of the command date into the shell variable mydate?
mydate="$(date)"
mydate="exec date"
mydate="$((date))"
mydate="date"
mydate="${date}"
Referência recomendada para estudo
Command substitution using $(...) is the standard and recommended way to capture the output of a command into a variable.
$(...)