title: Change nice value of a process
body: <p>I need to write a script for changing the nice value of a process with the new value and the process to be changed given my the command line as such:</p>
  <pre><code>$ bash script.sh 'cat' 15
  </code></pre>
  <p>I tried doing something like this:</p>
  <pre><code>$ pidof $1 | nice -$2 $1
  </code></pre>
  <p>but that didn't work and now I'm quite lost, since I'm new to this stuff. Any help is appreciated.</p>