title: How to get this data using the DRY concept?
body: <p>I am working with an API that returns a list of ingredients for each item. Instead of having the ingredients in an array, it lists them in their own key:value pair like so:</p>
  
  <pre><code>{ingredient1: "item", ingredient2: "item2"}
  </code></pre>
  
  <p>My first thought was to use a For-loop, but I'm not really sure how to execute that. In my head it would be something like this(this doesn't actually work):</p>
  
  <pre><code>for(let i = 1; i &lt; 16; i++) {console.log(data.ingredient + i)}
  </code></pre>
  
  <p>This, of course, is viewed as a mathematical operation not concatenation. How would I go about this correctly?</p>
  
  <p>Thank you.</p>