title: Simple bash script using "set" command
body: <p>I am supposed to make a script that prints all sizes and file-names in the current directory, ordered by size, using the "set" command.</p>
  
  <pre><code>#!/bin/bash
  
  touch /tmp/unsorted
  
  IFS='@'
  export IFS
  
  ls -l | tr -s " " "@" | sed '1d' &gt; /tmp/tempLS
  
  while read line
  do
      ##set probably goes here##
      echo $5 $9 &gt;&gt; /tmp/unsorted
  done &lt; /tmp/tempLS
  
  sort -n /tmp/unsorted
  rm -rf /tmp/unsorted
  </code></pre>
  
  <p>By logic, this is the script that should work, but it produces only blank lines.
  After discussion with my classmates, we think that the "set" command must go first in the while loop. The problem is that we cant understand what the "set" command does, and how to use it. Please help. Thank you.</p>