table_gen.sh 405 B

1234567891011121314151617181920212223
  1. #! /bin/bash
  2. start_skill=$1
  3. end_skill=$2
  4. max_hours=$3
  5. printf "%-5s" Skill
  6. for h in $(seq 5 5 $max_hours); do
  7. printf "%5d" "$h"
  8. done
  9. printf "\n"
  10. for dash in $(seq 0 $(( max_hours+5 ))); do
  11. printf "-"
  12. done
  13. printf "\n"
  14. for s in $(seq $start_skill 5 $end_skill); do
  15. printf "%3s " $s
  16. for h in $(seq 5 5 $max_hours); do
  17. printf "%5d" "$(rqt $s $h hours)"
  18. done
  19. printf "\n"
  20. done