title: Is there a way to split an infinite or a number of choosing into 3 or more randomized sizes for a population type of code?
body: <p>I'm trying to figure out how to add onto my code where it randomly splits the number of my choosing into a number of my choosing size. For example, I want to have 3 cities where my randomized humans are put into, and I can choose how many I create, let's say</p>
  <pre><code>amount_of_humans_to_make = 98327
  </code></pre>
  <p>And these humans are put into a list &quot;<code>li[]</code>&quot; And I want to randomly put them into a chosen amount of cities, for simple sake &quot;3&quot;. And it has to be random sizes without duplicates, I don't want it to be hard coded, I want to be able to have the freedom of changing the numbers to what ever I want. This is the code I use right now for the cities</p>
  <pre><code>def make_cities(populations):
    City_Name = [&quot;NewYork&quot;, &quot;Alabama&quot;, &quot;Boston&quot;]
    res = [
      make_city(populations[0:30], City_Name[0]),
      make_city(populations[31:60], City_Name[1]),
      make_city(populations[61:90], City_Name[2])
      ]
    return res
  </code></pre>
  <p>If anyone could help would be much appreciated.</p>