title: How are data structures created in declarative programming?
body: <p>An article I read gave this example for the difference between declarative and imperative programming:</p>
  
  <hr>
  
  <p><strong>Declarative</strong></p>
  
  <pre><code>small_nums = [x for x in range(20) if x &lt; 5]
  </code></pre>
  
  <hr>
  
  <p><strong>Imperative</strong></p>
  
  <pre><code>small_nums = []
  for i in range(20):
  if i &lt; 5:
  small_nums.append(i)
  </code></pre>
  
  <hr>
  
  <p>The imperative example declares an array. How is the data stored in the declarative example? Or is the storage structure determined by a separate piece of software?</p>