fork download
  1. import itertools, collections
  2.  
  3. persons = 'ABCD'
  4. number_of_cookies = 16
  5.  
  6. n = len(persons)
  7. i = 0
  8. for comb in itertools.combinations_with_replacement(persons, number_of_cookies):
  9. counter = collections.Counter(comb)
  10. if len(counter) != n:
  11. i += 1
  12. counts = list(counter.items())
  13. counts.sort()
  14. print((str(i)+':').ljust(4), counts)
  15.  
Success #stdin #stdout 0.05s 9424KB
stdin
Standard input is empty
stdout
1:   [('A', 16)]
2:   [('A', 15), ('B', 1)]
3:   [('A', 15), ('C', 1)]
4:   [('A', 15), ('D', 1)]
5:   [('A', 14), ('B', 2)]
6:   [('A', 14), ('B', 1), ('C', 1)]
7:   [('A', 14), ('B', 1), ('D', 1)]
8:   [('A', 14), ('C', 2)]
9:   [('A', 14), ('C', 1), ('D', 1)]
10:  [('A', 14), ('D', 2)]
11:  [('A', 13), ('B', 3)]
12:  [('A', 13), ('B', 2), ('C', 1)]
13:  [('A', 13), ('B', 2), ('D', 1)]
14:  [('A', 13), ('B', 1), ('C', 2)]
15:  [('A', 13), ('B', 1), ('D', 2)]
16:  [('A', 13), ('C', 3)]
17:  [('A', 13), ('C', 2), ('D', 1)]
18:  [('A', 13), ('C', 1), ('D', 2)]
19:  [('A', 13), ('D', 3)]
20:  [('A', 12), ('B', 4)]
21:  [('A', 12), ('B', 3), ('C', 1)]
22:  [('A', 12), ('B', 3), ('D', 1)]
23:  [('A', 12), ('B', 2), ('C', 2)]
24:  [('A', 12), ('B', 2), ('D', 2)]
25:  [('A', 12), ('B', 1), ('C', 3)]
26:  [('A', 12), ('B', 1), ('D', 3)]
27:  [('A', 12), ('C', 4)]
28:  [('A', 12), ('C', 3), ('D', 1)]
29:  [('A', 12), ('C', 2), ('D', 2)]
30:  [('A', 12), ('C', 1), ('D', 3)]
31:  [('A', 12), ('D', 4)]
32:  [('A', 11), ('B', 5)]
33:  [('A', 11), ('B', 4), ('C', 1)]
34:  [('A', 11), ('B', 4), ('D', 1)]
35:  [('A', 11), ('B', 3), ('C', 2)]
36:  [('A', 11), ('B', 3), ('D', 2)]
37:  [('A', 11), ('B', 2), ('C', 3)]
38:  [('A', 11), ('B', 2), ('D', 3)]
39:  [('A', 11), ('B', 1), ('C', 4)]
40:  [('A', 11), ('B', 1), ('D', 4)]
41:  [('A', 11), ('C', 5)]
42:  [('A', 11), ('C', 4), ('D', 1)]
43:  [('A', 11), ('C', 3), ('D', 2)]
44:  [('A', 11), ('C', 2), ('D', 3)]
45:  [('A', 11), ('C', 1), ('D', 4)]
46:  [('A', 11), ('D', 5)]
47:  [('A', 10), ('B', 6)]
48:  [('A', 10), ('B', 5), ('C', 1)]
49:  [('A', 10), ('B', 5), ('D', 1)]
50:  [('A', 10), ('B', 4), ('C', 2)]
51:  [('A', 10), ('B', 4), ('D', 2)]
52:  [('A', 10), ('B', 3), ('C', 3)]
53:  [('A', 10), ('B', 3), ('D', 3)]
54:  [('A', 10), ('B', 2), ('C', 4)]
55:  [('A', 10), ('B', 2), ('D', 4)]
56:  [('A', 10), ('B', 1), ('C', 5)]
57:  [('A', 10), ('B', 1), ('D', 5)]
58:  [('A', 10), ('C', 6)]
59:  [('A', 10), ('C', 5), ('D', 1)]
60:  [('A', 10), ('C', 4), ('D', 2)]
61:  [('A', 10), ('C', 3), ('D', 3)]
62:  [('A', 10), ('C', 2), ('D', 4)]
63:  [('A', 10), ('C', 1), ('D', 5)]
64:  [('A', 10), ('D', 6)]
65:  [('A', 9), ('B', 7)]
66:  [('A', 9), ('B', 6), ('C', 1)]
67:  [('A', 9), ('B', 6), ('D', 1)]
68:  [('A', 9), ('B', 5), ('C', 2)]
69:  [('A', 9), ('B', 5), ('D', 2)]
70:  [('A', 9), ('B', 4), ('C', 3)]
71:  [('A', 9), ('B', 4), ('D', 3)]
72:  [('A', 9), ('B', 3), ('C', 4)]
73:  [('A', 9), ('B', 3), ('D', 4)]
74:  [('A', 9), ('B', 2), ('C', 5)]
75:  [('A', 9), ('B', 2), ('D', 5)]
76:  [('A', 9), ('B', 1), ('C', 6)]
77:  [('A', 9), ('B', 1), ('D', 6)]
78:  [('A', 9), ('C', 7)]
79:  [('A', 9), ('C', 6), ('D', 1)]
80:  [('A', 9), ('C', 5), ('D', 2)]
81:  [('A', 9), ('C', 4), ('D', 3)]
82:  [('A', 9), ('C', 3), ('D', 4)]
83:  [('A', 9), ('C', 2), ('D', 5)]
84:  [('A', 9), ('C', 1), ('D', 6)]
85:  [('A', 9), ('D', 7)]
86:  [('A', 8), ('B', 8)]
87:  [('A', 8), ('B', 7), ('C', 1)]
88:  [('A', 8), ('B', 7), ('D', 1)]
89:  [('A', 8), ('B', 6), ('C', 2)]
90:  [('A', 8), ('B', 6), ('D', 2)]
91:  [('A', 8), ('B', 5), ('C', 3)]
92:  [('A', 8), ('B', 5), ('D', 3)]
93:  [('A', 8), ('B', 4), ('C', 4)]
94:  [('A', 8), ('B', 4), ('D', 4)]
95:  [('A', 8), ('B', 3), ('C', 5)]
96:  [('A', 8), ('B', 3), ('D', 5)]
97:  [('A', 8), ('B', 2), ('C', 6)]
98:  [('A', 8), ('B', 2), ('D', 6)]
99:  [('A', 8), ('B', 1), ('C', 7)]
100: [('A', 8), ('B', 1), ('D', 7)]
101: [('A', 8), ('C', 8)]
102: [('A', 8), ('C', 7), ('D', 1)]
103: [('A', 8), ('C', 6), ('D', 2)]
104: [('A', 8), ('C', 5), ('D', 3)]
105: [('A', 8), ('C', 4), ('D', 4)]
106: [('A', 8), ('C', 3), ('D', 5)]
107: [('A', 8), ('C', 2), ('D', 6)]
108: [('A', 8), ('C', 1), ('D', 7)]
109: [('A', 8), ('D', 8)]
110: [('A', 7), ('B', 9)]
111: [('A', 7), ('B', 8), ('C', 1)]
112: [('A', 7), ('B', 8), ('D', 1)]
113: [('A', 7), ('B', 7), ('C', 2)]
114: [('A', 7), ('B', 7), ('D', 2)]
115: [('A', 7), ('B', 6), ('C', 3)]
116: [('A', 7), ('B', 6), ('D', 3)]
117: [('A', 7), ('B', 5), ('C', 4)]
118: [('A', 7), ('B', 5), ('D', 4)]
119: [('A', 7), ('B', 4), ('C', 5)]
120: [('A', 7), ('B', 4), ('D', 5)]
121: [('A', 7), ('B', 3), ('C', 6)]
122: [('A', 7), ('B', 3), ('D', 6)]
123: [('A', 7), ('B', 2), ('C', 7)]
124: [('A', 7), ('B', 2), ('D', 7)]
125: [('A', 7), ('B', 1), ('C', 8)]
126: [('A', 7), ('B', 1), ('D', 8)]
127: [('A', 7), ('C', 9)]
128: [('A', 7), ('C', 8), ('D', 1)]
129: [('A', 7), ('C', 7), ('D', 2)]
130: [('A', 7), ('C', 6), ('D', 3)]
131: [('A', 7), ('C', 5), ('D', 4)]
132: [('A', 7), ('C', 4), ('D', 5)]
133: [('A', 7), ('C', 3), ('D', 6)]
134: [('A', 7), ('C', 2), ('D', 7)]
135: [('A', 7), ('C', 1), ('D', 8)]
136: [('A', 7), ('D', 9)]
137: [('A', 6), ('B', 10)]
138: [('A', 6), ('B', 9), ('C', 1)]
139: [('A', 6), ('B', 9), ('D', 1)]
140: [('A', 6), ('B', 8), ('C', 2)]
141: [('A', 6), ('B', 8), ('D', 2)]
142: [('A', 6), ('B', 7), ('C', 3)]
143: [('A', 6), ('B', 7), ('D', 3)]
144: [('A', 6), ('B', 6), ('C', 4)]
145: [('A', 6), ('B', 6), ('D', 4)]
146: [('A', 6), ('B', 5), ('C', 5)]
147: [('A', 6), ('B', 5), ('D', 5)]
148: [('A', 6), ('B', 4), ('C', 6)]
149: [('A', 6), ('B', 4), ('D', 6)]
150: [('A', 6), ('B', 3), ('C', 7)]
151: [('A', 6), ('B', 3), ('D', 7)]
152: [('A', 6), ('B', 2), ('C', 8)]
153: [('A', 6), ('B', 2), ('D', 8)]
154: [('A', 6), ('B', 1), ('C', 9)]
155: [('A', 6), ('B', 1), ('D', 9)]
156: [('A', 6), ('C', 10)]
157: [('A', 6), ('C', 9), ('D', 1)]
158: [('A', 6), ('C', 8), ('D', 2)]
159: [('A', 6), ('C', 7), ('D', 3)]
160: [('A', 6), ('C', 6), ('D', 4)]
161: [('A', 6), ('C', 5), ('D', 5)]
162: [('A', 6), ('C', 4), ('D', 6)]
163: [('A', 6), ('C', 3), ('D', 7)]
164: [('A', 6), ('C', 2), ('D', 8)]
165: [('A', 6), ('C', 1), ('D', 9)]
166: [('A', 6), ('D', 10)]
167: [('A', 5), ('B', 11)]
168: [('A', 5), ('B', 10), ('C', 1)]
169: [('A', 5), ('B', 10), ('D', 1)]
170: [('A', 5), ('B', 9), ('C', 2)]
171: [('A', 5), ('B', 9), ('D', 2)]
172: [('A', 5), ('B', 8), ('C', 3)]
173: [('A', 5), ('B', 8), ('D', 3)]
174: [('A', 5), ('B', 7), ('C', 4)]
175: [('A', 5), ('B', 7), ('D', 4)]
176: [('A', 5), ('B', 6), ('C', 5)]
177: [('A', 5), ('B', 6), ('D', 5)]
178: [('A', 5), ('B', 5), ('C', 6)]
179: [('A', 5), ('B', 5), ('D', 6)]
180: [('A', 5), ('B', 4), ('C', 7)]
181: [('A', 5), ('B', 4), ('D', 7)]
182: [('A', 5), ('B', 3), ('C', 8)]
183: [('A', 5), ('B', 3), ('D', 8)]
184: [('A', 5), ('B', 2), ('C', 9)]
185: [('A', 5), ('B', 2), ('D', 9)]
186: [('A', 5), ('B', 1), ('C', 10)]
187: [('A', 5), ('B', 1), ('D', 10)]
188: [('A', 5), ('C', 11)]
189: [('A', 5), ('C', 10), ('D', 1)]
190: [('A', 5), ('C', 9), ('D', 2)]
191: [('A', 5), ('C', 8), ('D', 3)]
192: [('A', 5), ('C', 7), ('D', 4)]
193: [('A', 5), ('C', 6), ('D', 5)]
194: [('A', 5), ('C', 5), ('D', 6)]
195: [('A', 5), ('C', 4), ('D', 7)]
196: [('A', 5), ('C', 3), ('D', 8)]
197: [('A', 5), ('C', 2), ('D', 9)]
198: [('A', 5), ('C', 1), ('D', 10)]
199: [('A', 5), ('D', 11)]
200: [('A', 4), ('B', 12)]
201: [('A', 4), ('B', 11), ('C', 1)]
202: [('A', 4), ('B', 11), ('D', 1)]
203: [('A', 4), ('B', 10), ('C', 2)]
204: [('A', 4), ('B', 10), ('D', 2)]
205: [('A', 4), ('B', 9), ('C', 3)]
206: [('A', 4), ('B', 9), ('D', 3)]
207: [('A', 4), ('B', 8), ('C', 4)]
208: [('A', 4), ('B', 8), ('D', 4)]
209: [('A', 4), ('B', 7), ('C', 5)]
210: [('A', 4), ('B', 7), ('D', 5)]
211: [('A', 4), ('B', 6), ('C', 6)]
212: [('A', 4), ('B', 6), ('D', 6)]
213: [('A', 4), ('B', 5), ('C', 7)]
214: [('A', 4), ('B', 5), ('D', 7)]
215: [('A', 4), ('B', 4), ('C', 8)]
216: [('A', 4), ('B', 4), ('D', 8)]
217: [('A', 4), ('B', 3), ('C', 9)]
218: [('A', 4), ('B', 3), ('D', 9)]
219: [('A', 4), ('B', 2), ('C', 10)]
220: [('A', 4), ('B', 2), ('D', 10)]
221: [('A', 4), ('B', 1), ('C', 11)]
222: [('A', 4), ('B', 1), ('D', 11)]
223: [('A', 4), ('C', 12)]
224: [('A', 4), ('C', 11), ('D', 1)]
225: [('A', 4), ('C', 10), ('D', 2)]
226: [('A', 4), ('C', 9), ('D', 3)]
227: [('A', 4), ('C', 8), ('D', 4)]
228: [('A', 4), ('C', 7), ('D', 5)]
229: [('A', 4), ('C', 6), ('D', 6)]
230: [('A', 4), ('C', 5), ('D', 7)]
231: [('A', 4), ('C', 4), ('D', 8)]
232: [('A', 4), ('C', 3), ('D', 9)]
233: [('A', 4), ('C', 2), ('D', 10)]
234: [('A', 4), ('C', 1), ('D', 11)]
235: [('A', 4), ('D', 12)]
236: [('A', 3), ('B', 13)]
237: [('A', 3), ('B', 12), ('C', 1)]
238: [('A', 3), ('B', 12), ('D', 1)]
239: [('A', 3), ('B', 11), ('C', 2)]
240: [('A', 3), ('B', 11), ('D', 2)]
241: [('A', 3), ('B', 10), ('C', 3)]
242: [('A', 3), ('B', 10), ('D', 3)]
243: [('A', 3), ('B', 9), ('C', 4)]
244: [('A', 3), ('B', 9), ('D', 4)]
245: [('A', 3), ('B', 8), ('C', 5)]
246: [('A', 3), ('B', 8), ('D', 5)]
247: [('A', 3), ('B', 7), ('C', 6)]
248: [('A', 3), ('B', 7), ('D', 6)]
249: [('A', 3), ('B', 6), ('C', 7)]
250: [('A', 3), ('B', 6), ('D', 7)]
251: [('A', 3), ('B', 5), ('C', 8)]
252: [('A', 3), ('B', 5), ('D', 8)]
253: [('A', 3), ('B', 4), ('C', 9)]
254: [('A', 3), ('B', 4), ('D', 9)]
255: [('A', 3), ('B', 3), ('C', 10)]
256: [('A', 3), ('B', 3), ('D', 10)]
257: [('A', 3), ('B', 2), ('C', 11)]
258: [('A', 3), ('B', 2), ('D', 11)]
259: [('A', 3), ('B', 1), ('C', 12)]
260: [('A', 3), ('B', 1), ('D', 12)]
261: [('A', 3), ('C', 13)]
262: [('A', 3), ('C', 12), ('D', 1)]
263: [('A', 3), ('C', 11), ('D', 2)]
264: [('A', 3), ('C', 10), ('D', 3)]
265: [('A', 3), ('C', 9), ('D', 4)]
266: [('A', 3), ('C', 8), ('D', 5)]
267: [('A', 3), ('C', 7), ('D', 6)]
268: [('A', 3), ('C', 6), ('D', 7)]
269: [('A', 3), ('C', 5), ('D', 8)]
270: [('A', 3), ('C', 4), ('D', 9)]
271: [('A', 3), ('C', 3), ('D', 10)]
272: [('A', 3), ('C', 2), ('D', 11)]
273: [('A', 3), ('C', 1), ('D', 12)]
274: [('A', 3), ('D', 13)]
275: [('A', 2), ('B', 14)]
276: [('A', 2), ('B', 13), ('C', 1)]
277: [('A', 2), ('B', 13), ('D', 1)]
278: [('A', 2), ('B', 12), ('C', 2)]
279: [('A', 2), ('B', 12), ('D', 2)]
280: [('A', 2), ('B', 11), ('C', 3)]
281: [('A', 2), ('B', 11), ('D', 3)]
282: [('A', 2), ('B', 10), ('C', 4)]
283: [('A', 2), ('B', 10), ('D', 4)]
284: [('A', 2), ('B', 9), ('C', 5)]
285: [('A', 2), ('B', 9), ('D', 5)]
286: [('A', 2), ('B', 8), ('C', 6)]
287: [('A', 2), ('B', 8), ('D', 6)]
288: [('A', 2), ('B', 7), ('C', 7)]
289: [('A', 2), ('B', 7), ('D', 7)]
290: [('A', 2), ('B', 6), ('C', 8)]
291: [('A', 2), ('B', 6), ('D', 8)]
292: [('A', 2), ('B', 5), ('C', 9)]
293: [('A', 2), ('B', 5), ('D', 9)]
294: [('A', 2), ('B', 4), ('C', 10)]
295: [('A', 2), ('B', 4), ('D', 10)]
296: [('A', 2), ('B', 3), ('C', 11)]
297: [('A', 2), ('B', 3), ('D', 11)]
298: [('A', 2), ('B', 2), ('C', 12)]
299: [('A', 2), ('B', 2), ('D', 12)]
300: [('A', 2), ('B', 1), ('C', 13)]
301: [('A', 2), ('B', 1), ('D', 13)]
302: [('A', 2), ('C', 14)]
303: [('A', 2), ('C', 13), ('D', 1)]
304: [('A', 2), ('C', 12), ('D', 2)]
305: [('A', 2), ('C', 11), ('D', 3)]
306: [('A', 2), ('C', 10), ('D', 4)]
307: [('A', 2), ('C', 9), ('D', 5)]
308: [('A', 2), ('C', 8), ('D', 6)]
309: [('A', 2), ('C', 7), ('D', 7)]
310: [('A', 2), ('C', 6), ('D', 8)]
311: [('A', 2), ('C', 5), ('D', 9)]
312: [('A', 2), ('C', 4), ('D', 10)]
313: [('A', 2), ('C', 3), ('D', 11)]
314: [('A', 2), ('C', 2), ('D', 12)]
315: [('A', 2), ('C', 1), ('D', 13)]
316: [('A', 2), ('D', 14)]
317: [('A', 1), ('B', 15)]
318: [('A', 1), ('B', 14), ('C', 1)]
319: [('A', 1), ('B', 14), ('D', 1)]
320: [('A', 1), ('B', 13), ('C', 2)]
321: [('A', 1), ('B', 13), ('D', 2)]
322: [('A', 1), ('B', 12), ('C', 3)]
323: [('A', 1), ('B', 12), ('D', 3)]
324: [('A', 1), ('B', 11), ('C', 4)]
325: [('A', 1), ('B', 11), ('D', 4)]
326: [('A', 1), ('B', 10), ('C', 5)]
327: [('A', 1), ('B', 10), ('D', 5)]
328: [('A', 1), ('B', 9), ('C', 6)]
329: [('A', 1), ('B', 9), ('D', 6)]
330: [('A', 1), ('B', 8), ('C', 7)]
331: [('A', 1), ('B', 8), ('D', 7)]
332: [('A', 1), ('B', 7), ('C', 8)]
333: [('A', 1), ('B', 7), ('D', 8)]
334: [('A', 1), ('B', 6), ('C', 9)]
335: [('A', 1), ('B', 6), ('D', 9)]
336: [('A', 1), ('B', 5), ('C', 10)]
337: [('A', 1), ('B', 5), ('D', 10)]
338: [('A', 1), ('B', 4), ('C', 11)]
339: [('A', 1), ('B', 4), ('D', 11)]
340: [('A', 1), ('B', 3), ('C', 12)]
341: [('A', 1), ('B', 3), ('D', 12)]
342: [('A', 1), ('B', 2), ('C', 13)]
343: [('A', 1), ('B', 2), ('D', 13)]
344: [('A', 1), ('B', 1), ('C', 14)]
345: [('A', 1), ('B', 1), ('D', 14)]
346: [('A', 1), ('C', 15)]
347: [('A', 1), ('C', 14), ('D', 1)]
348: [('A', 1), ('C', 13), ('D', 2)]
349: [('A', 1), ('C', 12), ('D', 3)]
350: [('A', 1), ('C', 11), ('D', 4)]
351: [('A', 1), ('C', 10), ('D', 5)]
352: [('A', 1), ('C', 9), ('D', 6)]
353: [('A', 1), ('C', 8), ('D', 7)]
354: [('A', 1), ('C', 7), ('D', 8)]
355: [('A', 1), ('C', 6), ('D', 9)]
356: [('A', 1), ('C', 5), ('D', 10)]
357: [('A', 1), ('C', 4), ('D', 11)]
358: [('A', 1), ('C', 3), ('D', 12)]
359: [('A', 1), ('C', 2), ('D', 13)]
360: [('A', 1), ('C', 1), ('D', 14)]
361: [('A', 1), ('D', 15)]
362: [('B', 16)]
363: [('B', 15), ('C', 1)]
364: [('B', 15), ('D', 1)]
365: [('B', 14), ('C', 2)]
366: [('B', 14), ('C', 1), ('D', 1)]
367: [('B', 14), ('D', 2)]
368: [('B', 13), ('C', 3)]
369: [('B', 13), ('C', 2), ('D', 1)]
370: [('B', 13), ('C', 1), ('D', 2)]
371: [('B', 13), ('D', 3)]
372: [('B', 12), ('C', 4)]
373: [('B', 12), ('C', 3), ('D', 1)]
374: [('B', 12), ('C', 2), ('D', 2)]
375: [('B', 12), ('C', 1), ('D', 3)]
376: [('B', 12), ('D', 4)]
377: [('B', 11), ('C', 5)]
378: [('B', 11), ('C', 4), ('D', 1)]
379: [('B', 11), ('C', 3), ('D', 2)]
380: [('B', 11), ('C', 2), ('D', 3)]
381: [('B', 11), ('C', 1), ('D', 4)]
382: [('B', 11), ('D', 5)]
383: [('B', 10), ('C', 6)]
384: [('B', 10), ('C', 5), ('D', 1)]
385: [('B', 10), ('C', 4), ('D', 2)]
386: [('B', 10), ('C', 3), ('D', 3)]
387: [('B', 10), ('C', 2), ('D', 4)]
388: [('B', 10), ('C', 1), ('D', 5)]
389: [('B', 10), ('D', 6)]
390: [('B', 9), ('C', 7)]
391: [('B', 9), ('C', 6), ('D', 1)]
392: [('B', 9), ('C', 5), ('D', 2)]
393: [('B', 9), ('C', 4), ('D', 3)]
394: [('B', 9), ('C', 3), ('D', 4)]
395: [('B', 9), ('C', 2), ('D', 5)]
396: [('B', 9), ('C', 1), ('D', 6)]
397: [('B', 9), ('D', 7)]
398: [('B', 8), ('C', 8)]
399: [('B', 8), ('C', 7), ('D', 1)]
400: [('B', 8), ('C', 6), ('D', 2)]
401: [('B', 8), ('C', 5), ('D', 3)]
402: [('B', 8), ('C', 4), ('D', 4)]
403: [('B', 8), ('C', 3), ('D', 5)]
404: [('B', 8), ('C', 2), ('D', 6)]
405: [('B', 8), ('C', 1), ('D', 7)]
406: [('B', 8), ('D', 8)]
407: [('B', 7), ('C', 9)]
408: [('B', 7), ('C', 8), ('D', 1)]
409: [('B', 7), ('C', 7), ('D', 2)]
410: [('B', 7), ('C', 6), ('D', 3)]
411: [('B', 7), ('C', 5), ('D', 4)]
412: [('B', 7), ('C', 4), ('D', 5)]
413: [('B', 7), ('C', 3), ('D', 6)]
414: [('B', 7), ('C', 2), ('D', 7)]
415: [('B', 7), ('C', 1), ('D', 8)]
416: [('B', 7), ('D', 9)]
417: [('B', 6), ('C', 10)]
418: [('B', 6), ('C', 9), ('D', 1)]
419: [('B', 6), ('C', 8), ('D', 2)]
420: [('B', 6), ('C', 7), ('D', 3)]
421: [('B', 6), ('C', 6), ('D', 4)]
422: [('B', 6), ('C', 5), ('D', 5)]
423: [('B', 6), ('C', 4), ('D', 6)]
424: [('B', 6), ('C', 3), ('D', 7)]
425: [('B', 6), ('C', 2), ('D', 8)]
426: [('B', 6), ('C', 1), ('D', 9)]
427: [('B', 6), ('D', 10)]
428: [('B', 5), ('C', 11)]
429: [('B', 5), ('C', 10), ('D', 1)]
430: [('B', 5), ('C', 9), ('D', 2)]
431: [('B', 5), ('C', 8), ('D', 3)]
432: [('B', 5), ('C', 7), ('D', 4)]
433: [('B', 5), ('C', 6), ('D', 5)]
434: [('B', 5), ('C', 5), ('D', 6)]
435: [('B', 5), ('C', 4), ('D', 7)]
436: [('B', 5), ('C', 3), ('D', 8)]
437: [('B', 5), ('C', 2), ('D', 9)]
438: [('B', 5), ('C', 1), ('D', 10)]
439: [('B', 5), ('D', 11)]
440: [('B', 4), ('C', 12)]
441: [('B', 4), ('C', 11), ('D', 1)]
442: [('B', 4), ('C', 10), ('D', 2)]
443: [('B', 4), ('C', 9), ('D', 3)]
444: [('B', 4), ('C', 8), ('D', 4)]
445: [('B', 4), ('C', 7), ('D', 5)]
446: [('B', 4), ('C', 6), ('D', 6)]
447: [('B', 4), ('C', 5), ('D', 7)]
448: [('B', 4), ('C', 4), ('D', 8)]
449: [('B', 4), ('C', 3), ('D', 9)]
450: [('B', 4), ('C', 2), ('D', 10)]
451: [('B', 4), ('C', 1), ('D', 11)]
452: [('B', 4), ('D', 12)]
453: [('B', 3), ('C', 13)]
454: [('B', 3), ('C', 12), ('D', 1)]
455: [('B', 3), ('C', 11), ('D', 2)]
456: [('B', 3), ('C', 10), ('D', 3)]
457: [('B', 3), ('C', 9), ('D', 4)]
458: [('B', 3), ('C', 8), ('D', 5)]
459: [('B', 3), ('C', 7), ('D', 6)]
460: [('B', 3), ('C', 6), ('D', 7)]
461: [('B', 3), ('C', 5), ('D', 8)]
462: [('B', 3), ('C', 4), ('D', 9)]
463: [('B', 3), ('C', 3), ('D', 10)]
464: [('B', 3), ('C', 2), ('D', 11)]
465: [('B', 3), ('C', 1), ('D', 12)]
466: [('B', 3), ('D', 13)]
467: [('B', 2), ('C', 14)]
468: [('B', 2), ('C', 13), ('D', 1)]
469: [('B', 2), ('C', 12), ('D', 2)]
470: [('B', 2), ('C', 11), ('D', 3)]
471: [('B', 2), ('C', 10), ('D', 4)]
472: [('B', 2), ('C', 9), ('D', 5)]
473: [('B', 2), ('C', 8), ('D', 6)]
474: [('B', 2), ('C', 7), ('D', 7)]
475: [('B', 2), ('C', 6), ('D', 8)]
476: [('B', 2), ('C', 5), ('D', 9)]
477: [('B', 2), ('C', 4), ('D', 10)]
478: [('B', 2), ('C', 3), ('D', 11)]
479: [('B', 2), ('C', 2), ('D', 12)]
480: [('B', 2), ('C', 1), ('D', 13)]
481: [('B', 2), ('D', 14)]
482: [('B', 1), ('C', 15)]
483: [('B', 1), ('C', 14), ('D', 1)]
484: [('B', 1), ('C', 13), ('D', 2)]
485: [('B', 1), ('C', 12), ('D', 3)]
486: [('B', 1), ('C', 11), ('D', 4)]
487: [('B', 1), ('C', 10), ('D', 5)]
488: [('B', 1), ('C', 9), ('D', 6)]
489: [('B', 1), ('C', 8), ('D', 7)]
490: [('B', 1), ('C', 7), ('D', 8)]
491: [('B', 1), ('C', 6), ('D', 9)]
492: [('B', 1), ('C', 5), ('D', 10)]
493: [('B', 1), ('C', 4), ('D', 11)]
494: [('B', 1), ('C', 3), ('D', 12)]
495: [('B', 1), ('C', 2), ('D', 13)]
496: [('B', 1), ('C', 1), ('D', 14)]
497: [('B', 1), ('D', 15)]
498: [('C', 16)]
499: [('C', 15), ('D', 1)]
500: [('C', 14), ('D', 2)]
501: [('C', 13), ('D', 3)]
502: [('C', 12), ('D', 4)]
503: [('C', 11), ('D', 5)]
504: [('C', 10), ('D', 6)]
505: [('C', 9), ('D', 7)]
506: [('C', 8), ('D', 8)]
507: [('C', 7), ('D', 9)]
508: [('C', 6), ('D', 10)]
509: [('C', 5), ('D', 11)]
510: [('C', 4), ('D', 12)]
511: [('C', 3), ('D', 13)]
512: [('C', 2), ('D', 14)]
513: [('C', 1), ('D', 15)]
514: [('D', 16)]