title: Simple bar graph challenge using arrays
body: <p>I am trying to solve the following challenge, which is to create a bar graph program:</p>
  
  <p>"Write a program that draws bar graphs. It should:
   1. Ask the user for a list of numbers. The user enters them separated by commas, e.g. 10,4,2,7,5,1.
   2. Print a horizontal bar graph of the numbers in order. 
   3. Bars should be made up of '-'</p>
  
  <p>For example</p>
  
  <pre><code>10,4,2,7
  ----------
  ----
  --
  -------
  </code></pre>
  
  <p>Note: you can assume the user will only enter integers separated by commas with no spaces." </p>
  
  <p>This is a challenge that comes as part of a tutorial on Arrays, so I think that the aim is to use an array.</p>
  
  <p>My thinking is to convert the user's input into an array, iterate over each number and print the corresponding number of dashes for each number. I can't work out how to do this however. Any advice would be appreciated.</p>