Files
hpr_website/www/eps/hpr2689/hpr2689_bash14_ex5.sh

12 lines
210 B
Bash
Executable File

#!/bin/bash
#
# A demonstration that anything that generates a list of words or numbers can
# be used in a 'for' loop
#
for w in $(grep -E -v "'s$" /usr/share/dict/words | shuf -n 10); do
echo "$w"
done