1 2 3 4 5 6 7 8 9
#!/bin/sh # 200 background jobs, then one wait. i=0 while [ $i -lt 200 ]; do ( : ) & i=$((i + 1)) done wait echo "$i"