Code So far: today=\'date\' now=time echo \'enter input\' scanf input if (input=
ID: 644135 • Letter: C
Question
Code So far:
today='date'
now=time
echo 'enter input'
scanf input
if (input='Date')
then
echo $today
else
echo $now
fi
1. Bash Program Please help (Extra 600 pts for best solution)(No one answered) Write bash (shell) programs that make use of the following features. Linux commands reading user input accessing system information such as date, time, file number, size, and names arithmetic comparisons . if statements for var in list output commands Code So far: today='date' now=time echo 'enter input' scanf input if (input='Date') then echo $today else echo $now fiExplanation / Answer
now="$(date)" printf "Current date and time %s " "$now" now="$(date +'%d/%m/%Y')" printf "Current date in dd/mm/yyyy format %s " "$now" echo "Starting backup at $now, please wait..."
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.