這兩者是用於for, while, until 等迴圈控制下。break 會跳至done後方執行
,而continue會跳至done執行,繼續執行迴圈。
例
while
echo "Please enter data ('done' to exit):"
read response
do
if [ "$response" = "done" ]
then
break
fi
if [ "$response" = "" ]
then
continue
fi
_......
_......
process data
_......
_......
done