急!!!编写函数实现删除一维整型数组中指定元素,在主函数输入数组和输出数组(假设数组元素各不相同).
急!!!编写函数实现删除一维整型数组中指定元素,在主函数输入数组和输出数组(假设数组元素各不相同).
日期:2021-04-07 15:48:56 人气:3
#! /bin/bash
read -p "input the length of array: " length
for i in `seq $length`
do
read -p "input date: " array[$i]
i=$(($i+1))
done
for i in "${array[@]}"
do
read -p "input the length of array: " length
for i in `seq $length`
do
read -p "input date: " array[$i]
i=$(($i+1))
done
for i in "${array[@]}"
do