sleep NUMBER[SUFFIX] #Just use this command structure to wait/sleep
#Example:
sleep 5m #sleeps 5 minutes
sleep 0.1 #sleeps 0.1 seconds or 100 miliseconds
#Suffixes
s - seconds (default)
m - minutes
h - hours
d - days
When no suffix is specified, it defaults to seconds.
sleep 5s
#!/bin/bash
echo "Waiting for 2 seconds..."
sleep 2
echo "Task Completed"
#!/bin/bash
echo "Time Before Sleep Statement:"
date +"%H:%M:%S"
sleep 3
echo "Time After Sleep Statement:"
date +"%H:%M:%S"