Re: Sleep sort using BaSH

From NAT, 6 Years ago, written in Bash, viewed 698 times. This paste is a reply to Sleep sort using BaSH from NAT - view diff
URL https://code.nat.moe/view/d9aa9e10 Embed
Download Paste or View Raw
  1. #!/bin/bash
  2.  
  3. function output {
  4.         echo "after $1" | tclsh
  5.         echo -n "$1 "
  6. }
  7.  
  8. function sort {
  9.         for i in $*
  10.         do
  11.                 output $i &
  12.         done
  13. }
  14.  
  15. sort $*
  16. wait
  17. # use tclsh sleep instead of bash sleep. 1000 times efficiency.

Reply to "Re: Sleep sort using BaSH"

Here you can reply to the paste above

captcha