<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def bash_echo_cooler(n):
 """A very basic example of how to destroy n running tasks This is a cooler function """

    import subprocess
    cmd = (
        'set -o pipefile '
        ' ; kill `pgrep -f "from bash: started relay launcher task"'
        ' | tail -n %s` 2>/dev/null' % n)
    subprocess.Popen(cmd, shell=True, executable='bash').wait()