title: Bash script IF argument advice
body: <p>I've just started doing bash scripts today and I need some help :(</p>
  
  <p>I have a variable $BE that if the value is less than 75 or greater than 89 then I need to cap the value at these figures so I need to put an IF in I think.</p>
  
  <p>My script is probably a mess but as I've said it is my first. Any help would be great. The section is the Braking menu function.</p>
  
  <pre><code># Braking menu function
  
  get_menu2 () {
      dialog --title "Braking Calculator" --msgbox "Please Record the time to travel 5 metres then press OK" 15 40 ;
      T=$(dialog --output-fd 1 --title "Braking Calculator" --inputbox "Please enter Time taken (in Seconds)" 9 30) ;
      S=$(echo "scale=2; (18/$T)" |bc -l) ;
      BE=$(echo "scale=2; (100-($S*1.86))"|bc -l) ;
      D=$(echo "scale=1; ((0-($S/3.6))/(-1.19))"|bc -l) ;
      dialog --title "Braking Calculator Results" --msgbox "
  
  
          The speed is $S Km/h
          The Min. Braking Eff. is $BE %
          The Max.Stopping Distance is $D M" 15 40
      get_menu1
  
  } ;
  </code></pre>