Preisin
- preisin
- Arguments:
$1
- Value to search for[
$2
…] - Values of array to search over
- Output:
Exit code is
0
for found,1
for not found
Bash CLI version of preisin
See also
- preisin
- Arguments:
$1
- Value to search for (can be regex)[
$2
…] - Values of array to search over
- Output:
Returns
0
for found,1
for not found
Checks if any element in the array starts with a value
Example
preisin 3 11 22 33 44
# $? is 0
preisin 0 20 20 20
# $? is 1