Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function next() { echo $1; }
- function rest() { shift; echo $*; }
- space=" "
- rm results.txt
- function shift() {
- strings=$1
- for i in $strings; do
- strings=$(rest $strings)$space$(next $strings);
- if [ $(next $strings) != 'and' ]; then
- echo $strings;
- echo $strings >> results.txt;
- fi
- done;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement