33 lines
375 B
Bash
Executable file
33 lines
375 B
Bash
Executable file
#!/bin/bash
|
|
|
|
usage ()
|
|
{
|
|
echo 'mimimi by Klaus-Uwe Mitterer';
|
|
echo 'Usage: mimimi [-e]';
|
|
echo 'Options:';
|
|
echo '-e - Exponential';
|
|
exit;
|
|
}
|
|
|
|
i=1;
|
|
|
|
if [ $# -gt 0 ]
|
|
then if [ $1 != "-e" -o $# -gt 1 ]
|
|
then usage;
|
|
fi;
|
|
fi;
|
|
|
|
while true;
|
|
|
|
do for ((n=0;n<$i;n++));
|
|
do printf 'mi';
|
|
done;
|
|
|
|
printf '\n';
|
|
|
|
if [[ $1 = -e ]]
|
|
then i=$((i*i))
|
|
else i=$((i+1))
|
|
fi
|
|
|
|
done;
|