title: Algorithm to assign tasks to people, where some tasks require multiple people, and no person does the same task twice
body: <p>A teacher friend of mine asked me to cook up a program to help them assign classroom jobs to their students.  There are 23 kids and 12 different job types, where some jobs require multiple kids, totaling 23 available positions.  Each week they want to randomly assign new jobs to the kids, where no kid does the same job more than once for as long as that is possible.</p>
  
  <p>My thought process was to generate all possible assignments of kids to jobs following this rule, then step through the results one by one.  But I am stumped trying to come up with a practical algorithm to generate these assignment combinations.</p>
  
  <p>If anyone has any ideas for solutions, or can let me know I'm chasing an impossible one, I'd appreciate it!<br>
  I've pasted all the jobs and how many kids are needed for each below in case it's helpful.</p>
  
  <p>"Attendance": 1,<br>
  "Table Captain": 4,<br>
  "Teacher's Helper": 2,<br>
  "Board Eraser": 2,<br>
  "Light Switcher": 1,<br>
  "Librarian": 2,<br>
  "Lunch Helper": 1,<br>
  "Equipment Manager": 3,<br>
  "Trash Monitor": 2,<br>
  "Tech Specialist": 1,<br>
  "Paper Passer": 3,<br>
  "Pencil Sharpener": 1</p>