比赛 CSP2023-S模拟赛 评测结果 AAAAAAATATEEEEEEEEEE
题目名称 Maximized Combos 最终得分 40
用户昵称 心灵震荡 运行时间 4.053 s
代码语言 C++ 内存使用 4.05 MiB
提交时间 2023-10-17 21:02:33
显示代码纯文本
#include <bits/stdc++.h>
using namespace std;

int gg[45][45][45] = {{{1 }},{{2 },{0,1 }},{{3 },{1,2 },{0,0,1 }},{{4 },{3,3 },{0,2,2 },{0,0,0,1 }},{{5 },{6,4 },{1,6,3 },{0,1,2,2 },{0,0,0,0,1 }},{{6 },{10,5 },{4,12,4 },{0,6,6,3 },{0,0,2,2,2 },{0,0,0,0,0,1 }},{{7 },{15,6 },{10,20,5 },{1,18,12,4 },{0,3,9,6,3 },{0,0,1,2,2,2 },{0,0,0,0,0,0,1 }},{{8 },{21,7 },{20,30,6 },{5,40,20,5 },{0,16,24,12,4 },{0,1,9,9,6,3 },{0,0,0,2,2,2,2 },{0,0,0,0,0,0,0,1 }},{{9 },{28,8 },{35,42,7 },{15,75,30,6 },{1,50,50,20,5 },{0,10,34,24,12,4 },{0,0,6,12,9,6,3 },{0,0,0,1,2,2,2,2 },{0,0,0,0,0,0,0,0,1 }},{{10 },{36,9 },{56,56,8 },{35,126,42,7 },{6,120,90,30,6 },{0,45,90,50,20,5 },{0,4,36,40,24,12,4 },{0,0,3,12,12,9,6,3 },{0,0,0,0,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,1 }},{{11 },{45,10 },{84,72,9 },{70,196,56,8 },{21,245,147,42,7 },{1,140,195,90,30,6 },{0,30,125,100,50,20,5 },{0,1,30,54,40,24,12,4 },{0,0,1,9,15,12,9,6,3 },{0,0,0,0,1,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,1 }},{{12 },{55,11 },{120,90,10 },{126,288,72,9 },{56,448,224,56,8 },{7,350,371,147,42,7 },{0,126,330,210,90,30,6 },{0,15,140,165,100,50,20,5 },{0,0,20,60,60,40,24,12,4 },{0,0,0,6,15,15,12,9,6,3 },{0,0,0,0,0,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,1 }},{{13 },{66,12 },{165,110,11 },{210,405,90,10 },{126,756,324,72,9 },{28,756,644,224,56,8 },{1,392,735,392,147,42,7 },{0,90,456,405,210,90,30,6 },{0,5,130,230,175,100,50,20,5 },{0,0,10,58,78,60,40,24,12,4 },{0,0,0,3,12,18,15,12,9,6,3 },{0,0,0,0,0,1,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{14 },{78,13 },{220,132,12 },{330,550,110,11 },{252,1200,450,90,10 },{84,1470,1044,324,72,9 },{8,1008,1456,672,224,56,8 },{0,357,1197,861,392,147,42,7 },{0,50,530,666,420,210,90,30,6 },{0,1,100,280,270,175,100,50,20,5 },{0,0,4,48,88,84,60,40,24,12,4 },{0,0,0,1,9,18,18,15,12,9,6,3 },{0,0,0,0,0,0,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{15 },{91,14 },{286,156,13 },{495,726,132,12 },{462,1815,605,110,11 },{210,2640,1605,450,90,10 },{36,2268,2646,1080,324,72,9 },{1,1106,2716,1652,672,224,56,8 },{0,266,1652,1617,882,392,147,42,7 },{0,21,525,960,741,420,210,90,30,6 },{0,0,65,300,370,280,175,100,50,20,5 },{0,0,1,34,90,106,84,60,40,24,12,4 },{0,0,0,0,6,15,21,18,15,12,9,6,3 },{0,0,0,0,0,0,1,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{16 },{105,15 },{364,182,14 },{715,936,156,13 },{792,2640,792,132,12 },{462,4455,2365,605,110,11 },{120,4620,4500,1650,450,90,10 },{9,2898,5544,2934,1080,324,72,9 },{0,1016,4312,3472,1680,672,224,56,8 },{0,161,1967,2667,1743,882,392,147,42,7 },{0,6,450,1230,1170,756,420,210,90,30,6 },{0,0,35,285,460,410,280,175,100,50,20,5 },{0,0,0,20,84,120,112,84,60,40,24,12,4 },{0,0,0,0,3,12,21,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{17 },{120,16 },{455,210,15 },{1001,1183,182,14 },{1287,3718,1014,156,13 },{924,7150,3366,792,132,12 },{330,8712,7260,2420,605,110,11 },{45,6720,10440,4905,1650,450,90,10 },{1,3138,9912,6804,2970,1080,324,72,9 },{0,784,5944,6412,3668,1680,672,224,56,8 },{0,77,2051,3927,3087,1764,882,392,147,42,7 },{0,1,335,1415,1680,1245,756,420,210,90,30,6 },{0,0,15,240,525,550,420,280,175,100,50,20,5 },{0,0,0,10,70,126,138,112,84,60,40,24,12,4 },{0,0,0,0,1,9,18,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{18 },{136,17 },{560,240,16 },{1365,1470,210,15 },{2002,5096,1274,182,14 },{1716,11011,4654,1014,156,13 },{792,15444,11220,3432,792,132,12 },{165,14190,18447,7810,2420,605,110,11 },{10,8340,20700,12420,4950,1650,450,90,10 },{0,2907,15444,13860,7092,2970,1080,324,72,9 },{0,504,7224,10592,7168,3696,1680,672,224,56,8 },{0,28,1890,5222,4977,3213,1764,882,392,147,42,7 },{0,0,216,1470,2220,1890,1260,756,420,210,90,30,6 },{0,0,5,180,550,685,590,420,280,175,100,50,20,5 },{0,0,0,4,52,124,156,144,112,84,60,40,24,12,4 },{0,0,0,0,0,6,15,24,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{19 },{153,18 },{680,272,17 },{1820,1800,240,16 },{3003,6825,1575,210,15 },{3003,16380,6279,1274,182,14 },{1716,26026,16731,4732,1014,156,13 },{495,27819,30954,11946,3432,792,132,12 },{55,19800,40095,21417,7865,2420,605,110,11 },{1,8952,35850,27600,12825,4950,1650,450,90,10 },{0,2304,21303,25272,15120,7128,2970,1080,324,72,9 },{0,266,7826,15848,12748,7364,3696,1680,672,224,56,8 },{0,7,1547,6321,7392,5397,3234,1764,882,392,147,42,7 },{0,0,120,1386,2715,2670,1965,1260,756,420,210,90,30,6 },{0,0,1,120,530,800,775,600,420,280,175,100,50,20,5 },{0,0,0,1,34,114,166,174,144,112,84,60,40,24,12,4 },{0,0,0,0,0,3,12,21,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{20 },{171,19 },{816,306,18 },{2380,2176,272,17 },{4368,8960,1920,240,16 },{5005,23660,8295,1575,210,15 },{3432,42042,24206,6370,1274,182,14 },{1287,51337,49764,17667,4732,1014,156,13 },{220,43032,73084,35244,12012,3432,792,132,12 },{11,24057,76230,51480,21967,7865,2420,605,110,11 },{0,8350,55110,54900,29580,12870,4950,1650,450,90,10 },{0,1554,26322,41799,29304,15408,7128,2970,1080,324,72,9 },{0,112,7616,21672,20888,13504,7392,3696,1680,672,224,56,8 },{0,1,1127,7007,10192,8442,5523,3234,1764,882,392,147,42,7 },{0,0,56,1190,3086,3540,2880,1980,1260,756,420,210,90,30,6 },{0,0,0,70,470,880,960,815,600,420,280,175,100,50,20,5 },{0,0,0,0,20,96,168,196,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,1,9,18,27,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{21 },{190,20 },{969,342,19 },{3060,2601,306,18 },{6188,11560,2312,272,17 },{8008,33320,10760,1920,240,16 },{6435,65520,34125,8400,1575,210,15 },{3003,90090,77168,25389,6370,1274,182,14 },{715,87087,126698,55770,17745,4732,1014,156,13 },{66,58212,151074,91014,35970,12012,3432,792,132,12 },{1,25652,128865,110715,54450,22022,7865,2420,605,110,11 },{0,6765,76120,99120,61920,29985,12870,4950,1650,450,90,10 },{0,882,29394,63324,52299,30564,15444,7128,2970,1080,324,72,9 },{0,36,6692,27272,31808,23044,13700,7392,3696,1680,672,224,56,8 },{0,0,728,7147,13118,12397,8862,5544,3234,1764,882,392,147,42,7 },{0,0,21,930,3270,4431,3990,2955,1980,1260,756,420,210,90,30,6 },{0,0,0,35,385,910,1130,1050,825,600,420,280,175,100,50,20,5 },{0,0,0,0,10,74,162,210,214,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,6,15,24,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{22 },{210,21 },{1140,380,20 },{3876,3078,342,19 },{8568,14688,2754,306,18 },{12376,45900,13736,2312,272,17 },{11440,99008,47040,10880,1920,240,16 },{6435,151515,116025,35595,8400,1575,210,15 },{2002,166166,210574,85358,25480,6370,1274,182,14 },{286,129558,282568,153868,56706,17745,4732,1014,156,13 },{12,69564,277992,210144,95304,36036,12012,3432,792,132,12 },{0,24068,196130,216150,122265,55000,22022,7865,2420,605,110,11 },{0,4740,95370,164110,119250,63900,30030,12870,4950,1650,450,90,10 },{0,414,29862,88524,86760,56331,30852,15444,7128,2970,1080,324,72,9 },{0,8,5320,31752,45304,36904,23800,13728,7392,3696,1680,672,224,56,8 },{0,0,413,6727,15827,17199,13447,8988,5544,3234,1764,882,392,147,42,7 },{0,0,6,660,3240,5250,5256,4200,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,15,290,885,1270,1290,1090,825,600,420,280,175,100,50,20,5 },{0,0,0,0,4,52,148,216,240,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,3,12,21,30,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{23 },{231,22 },{1330,420,21 },{4845,3610,380,20 },{11628,18411,3249,342,19 },{18564,62016,17289,2754,306,18 },{19448,145656,63580,13872,2312,272,17 },{12870,245700,169848,48840,10880,1920,240,16 },{5005,301730,337610,126945,35700,8400,1575,210,15 },{1001,269269,503503,250432,86541,25480,6370,1274,182,14 },{78,171028,561418,379236,159874,56784,17745,4732,1014,156,13 },{1,73788,461175,440374,228294,96030,36036,12012,3432,792,132,12 },{0,19855,271403,387200,252285,125235,55055,22022,7865,2420,605,110,11 },{0,2850,109185,251130,213400,126270,64305,30030,12870,4950,1650,450,90,10 },{0,156,27720,114864,134724,97344,57591,30888,15444,7128,2970,1080,324,72,9 },{0,1,3822,34342,60648,55832,39060,23996,13728,7392,3696,1680,672,224,56,8 },{0,0,203,5852,17962,22638,19404,13867,9009,5544,3234,1764,882,392,147,42,7 },{0,0,1,425,3005,5900,6615,5706,4275,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,5,200,810,1365,1520,1380,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,1,34,126,214,258,258,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,1,9,18,27,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{24 },{253,23 },{1540,462,22 },{5985,4200,420,21 },{15504,22800,3800,380,20 },{27132,82365,21489,3249,342,19 },{31824,209304,84456,17442,2754,306,18 },{24310,386036,242896,65756,13872,2312,272,17 },{11440,525200,524720,184128,48960,10880,1920,240,16 },{3003,528528,860925,394485,128415,35700,8400,1575,210,15 },{364,388388,1073072,655746,258622,86632,25480,6370,1274,182,14 },{13,201630,1006577,847990,406692,160810,56784,17745,4732,1014,156,13 },{0,69576,696696,846912,501864,232584,96096,36036,12012,3432,792,132,12 },{0,14355,344135,641663,483395,263835,125785,55055,22022,7865,2420,605,110,11 },{0,1452,114852,357390,357510,233650,128250,64350,30030,12870,4950,1650,450,90,10 },{0,45,23562,138978,196884,158832,101376,57879,30888,15444,7128,2970,1080,324,72,9 },{0,0,2472,34608,76608,80192,60928,39816,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,84,4711,19222,28357,26754,20454,13993,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,246,2610,6300,7980,7440,5916,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,1,125,700,1400,1725,1680,1420,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,20,100,204,268,288,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,6,15,24,33,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{25 },{276,24 },{1771,506,23 },{7315,4851,462,22 },{20349,27930,4410,420,21 },{38760,107730,26410,3800,380,20 },{50388,294576,110466,21660,3249,342,19 },{43758,589968,340272,87057,17442,2754,306,18 },{24310,881348,793696,261256,65892,13872,2312,272,17 },{8008,988208,1420640,603960,185928,48960,10880,1920,240,16 },{1365,825825,1957410,1092975,405405,128520,35700,8400,1575,210,15 },{91,502502,2065063,1556919,695968,259805,86632,25480,6370,1274,182,14 },{1,212940,1645215,1740024,948090,412698,160888,56784,17745,4732,1014,156,13 },{0,58278,966186,1507506,1023594,520014,233310,96096,36036,12012,3432,792,132,12 },{0,9042,402292,990110,866888,519695,266805,125840,55055,22022,7865,2420,605,110,11 },{0,615,111420,475365,563970,407880,240670,128655,64350,30030,12870,4950,1650,450,90,10 },{0,9,18342,157374,271944,246024,169416,102636,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,1428,32572,91588,109760,90776,63084,40012,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,28,3507,19432,33887,35378,28959,20874,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,126,2121,6405,9240,9345,7890,5991,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,70,570,1370,1890,1975,1770,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,10,74,186,270,310,306,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,3,12,21,30,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{26 },{300,25 },{2024,552,24 },{8855,5566,506,23 },{26334,33880,5082,462,22 },{54264,138985,32130,4410,420,21 },{77520,406980,142500,26600,3800,380,20 },{75582,879852,468027,113544,21660,3249,342,19 },{48620,1432488,1172184,363528,87210,17442,2754,306,18 },{19448,1771978,2272696,901816,263432,65892,13872,2312,272,17 },{4368,1661088,3429920,1764480,618240,186048,48960,10880,1920,240,16 },{455,1161160,4020380,2744105,1150305,406875,128520,35700,8400,1575,210,15 },{14,585676,3625622,3391388,1713894,704158,259896,86632,25480,6370,1274,182,14 },{0,201643,2471625,3305302,2048618,975546,413634,160888,56784,17745,4732,1014,156,13 },{0,43252,1238028,2500356,1953028,1085304,524304,233376,96096,36036,12012,3432,792,132,12 },{0,4917,435567,1430000,1463990,964733,531245,267355,125840,55055,22022,7865,2420,605,110,11 },{0,210,99900,593340,841590,675630,428130,242650,128700,64350,30030,12870,4950,1650,450,90,10 },{0,1,13050,167274,356244,363288,270216,173448,102924,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,728,28672,103888,143584,129696,95872,63840,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,7,2408,18578,38717,44982,39494,30009,21000,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,56,1610,6206,10280,11340,10170,8100,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,35,435,1280,2000,2250,2135,1810,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,4,52,160,264,324,340,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,1,9,18,27,36,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{27 },{325,26 },{2300,600,25 },{10626,6348,552,24 },{33649,40733,5819,506,23 },{74613,177100,38731,5082,462,22 },{116280,553014,181545,32340,4410,420,21 },{125970,1283925,633270,146110,26600,3800,380,20 },{92378,2263584,1694781,497097,113715,21660,3249,342,19 },{43758,3063672,3537972,1317024,366129,87210,17442,2754,306,18 },{12376,3185936,5803698,2769776,920176,263568,65892,13872,2312,272,17 },{1820,2518516,7483060,4668080,1844280,620040,186048,48960,10880,1920,240,16 },{105,1476930,7537530,6318585,2982525,1161225,406980,128520,35700,8400,1575,210,15 },{1,616226,5855941,6838832,3907995,1754116,705341,259896,86632,25480,6370,1274,182,14 },{0,171106,3435874,5852860,4138420,2149004,981552,413712,160888,56784,17745,4732,1014,156,13 },{0,28314,1473252,3885321,3508506,2132130,1103454,525030,233376,96096,36036,12012,3432,792,132,12 },{0,2277,438207,1941445,2339645,1698125,1001033,534215,267410,125840,55055,22022,7865,2420,605,110,11 },{0,55,82830,697290,1192455,1066770,726120,435150,243055,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,8451,167274,443844,513108,413100,280800,174708,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,322,23618,112014,179964,178248,140280,98028,64036,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,1,1519,16807,42364,55097,52038,41699,30429,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,21,1140,5730,11001,13320,12705,10620,8175,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,15,310,1145,2040,2490,2500,2225,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,1,34,130,250,330,366,358,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,6,15,24,33,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{28 },{351,27 },{2600,650,26 },{12650,7200,600,25 },{42504,48576,6624,552,24 },{100947,223146,46299,5819,506,23 },{170544,740278,228690,38962,5082,462,22 },{203490,1837395,844284,185745,32340,4410,420,21 },{167960,3488400,2404260,669180,146300,26600,3800,380,20 },{92378,5129886,5376012,1885674,500175,113715,21660,3249,342,19 },{31824,5863572,9523332,4241160,1340280,366282,87210,17442,2754,306,18 },{6188,5175820,13394980,7697906,2878576,922352,263568,65892,13872,2312,272,17 },{560,3465280,14907776,11321440,5020320,1858560,620160,186048,48960,10880,1920,240,16 },{15,1704495,13008450,13467090,7152600,3039855,1162695,406980,128520,35700,8400,1575,210,15 },{0,585690,8760934,12857936,8324680,4065334,1762306,705432,259896,86632,25480,6370,1274,182,14 },{0,129844,4443738,9715433,7868302,4450446,2176460,982488,413712,160888,56784,17745,4732,1014,156,13 },{0,16236,1634556,5681676,5964816,3968328,2193840,1107744,525096,233376,96096,36036,12012,3432,792,132,12 },{0,880,410454,2486550,3552395,2848010,1796135,1012583,534765,267410,125840,55055,22022,7865,2420,605,110,11 },{0,10,63450,773640,1609200,1611390,1179510,746370,437130,243100,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,4950,157635,527130,695088,607392,437292,284832,174996,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,120,18200,114968,216552,236216,198240,145376,98784,64064,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,0,875,14392,44443,65114,66402,56154,42749,30555,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,6,750,5040,11340,15156,15420,13530,10830,8190,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,5,205,980,2005,2680,2850,2660,2265,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,0,20,100,228,328,384,396,364,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,3,12,21,30,39,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{29 },{378,28 },{2925,702,27 },{14950,8125,650,26 },{53130,57500,7500,600,25 },{134596,278300,54924,6624,552,24 },{245157,977592,285131,46552,5819,506,23 },{319770,2583658,1110648,233541,38962,5082,462,22 },{293930,5256825,3352930,888174,185955,32340,4410,420,21 },{184756,8348904,7994250,2652210,672790,146300,26600,3800,380,20 },{75582,10408352,15207486,6351795,1914744,500346,113715,21660,3249,342,19 },{18564,10153182,23170728,12349752,4386816,1342881,366282,87210,17442,2754,306,18 },{2380,7649252,28237612,19603448,8205866,2896936,922488,263568,65892,13872,2312,272,17 },{120,4343040,27350960,25409696,12626240,5100120,1860360,620160,186048,48960,10880,1920,240,16 },{1,1787606,20810153,26762645,16011905,7391475,3050775,1162800,406980,128520,35700,8400,1575,210,15 },{0,502593,12209393,22669829,16681756,8846019,4105556,1763489,705432,259896,86632,25480,6370,1274,182,14 },{0,87802,5370300,15188043,14155440,8723442,4550832,2182466,982566,413712,160888,56784,17745,4732,1014,156,13 },{0,8074,1695562,7848258,9637056,7033246,4147650,2211990,1108470,525096,233376,96096,36036,12012,3432,792,132,12 },{0,275,358215,3013329,5141290,4568960,3083795,1832435,1015553,534820,267410,125840,55055,22022,7865,2420,605,110,11 },{0,1,44802,812142,2073510,2335575,1841850,1230000,753390,437535,243100,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,2598,140142,597879,905172,861276,657288,447876,286092,175032,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,36,13104,112448,250572,302428,271272,208824,147532,98980,64064,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,0,455,11662,44737,74354,82194,73458,58359,43169,30576,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,1,455,4220,11270,16715,18216,16785,13980,10905,8190,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,1,125,800,1900,2805,3170,3100,2750,2275,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,0,10,74,198,318,394,426,414,364,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,1,9,18,27,36,42,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{30 },{406,29 },{3276,756,28 },{17550,9126,702,27 },{65780,67600,8450,650,26 },{177100,343850,64700,7500,600,25 },{346104,1275120,352176,55200,6624,552,24 },{490314,3575649,1443365,290697,46552,5819,506,23 },{497420,7763514,4604138,1163778,233772,38962,5082,462,22 },{352716,13247199,11658780,3670800,892374,185955,32340,4410,420,21 },{167960,17894200,23701740,9325200,2688120,672980,146300,26600,3800,380,20 },{50388,19124184,38885324,19332519,6543657,1917822,500346,113715,21660,3249,342,19 },{8568,16023384,51500412,32933556,13066812,4410072,1343034,366282,87210,17442,2754,306,18 },{680,10328656,54837172,46184512,21589456,8314666,2899112,922488,263568,65892,13872,2312,272,17 },{16,4969136,46538128,53170000,29618096,12979040,5114400,1860480,620160,186048,48960,10880,1920,240,16 },{0,1704510,31037580,49882560,33700485,16852290,7448805,3052245,1162800,406980,128520,35700,8400,1575,210,15 },{0,388752,15923180,37659818,31621772,18200364,9003358,4113746,1763580,705432,259896,86632,25480,6370,1274,182,14 },{0,52624,6084650,22447581,24202048,16271268,9035754,4578288,2183402,982566,413712,160888,56784,17745,4732,1014,156,13 },{0,3432,1647360,10272768,14847756,11919336,7495488,4209360,2216280,1108536,525096,233376,96096,36036,12012,3432,792,132,12 },{0,66,291192,3463812,7111929,7033730,5086235,3181805,1843985,1016103,534820,267410,125840,55055,22022,7865,2420,605,110,11 },{0,0,29050,808050,2556510,3256320,2773110,1954710,1250250,755370,437580,243100,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,1206,117594,648594,1135269,1180440,956232,681480,451908,286380,175032,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,8,8792,104888,279160,374696,360192,291264,213920,148288,99008,64064,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,0,210,8932,43232,82138,98819,93534,77574,59409,43295,30576,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,0,252,3360,10800,17880,20970,20316,17610,14190,10920,8190,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,0,70,620,1740,2850,3445,3530,3260,2790,2275,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,0,4,52,164,300,396,448,456,420,364,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,0,6,15,24,33,42,42,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{31 },{435,30 },{3654,812,29 },{20475,10206,756,28 },{80730,78975,9477,702,27 },{230230,421200,75725,8450,650,26 },{480700,1644500,431250,65000,7500,600,25 },{735471,4877334,1854996,358524,55200,6624,552,24 },{817190,11257994,6233920,1507121,290950,46552,5819,506,23 },{646646,20544909,16706833,5006848,1168629,233772,38962,5082,462,22 },{352716,29899464,36143415,13446300,3714690,892584,185955,32340,4410,420,21 },{125970,34754800,63519565,29604090,9574290,2691730,672980,146300,26600,3800,380,20 },{27132,32071962,90839874,53858312,20325744,6572727,1917993,500346,113715,21660,3249,342,19 },{3060,23159916,105471774,81221580,35884008,13212468,4412673,1343034,366282,87210,17442,2754,306,18 },{136,12778016,98800260,101429072,52933920,22098096,8333026,2899248,922488,263568,65892,13872,2312,272,17 },{1,5196626,73870748,104356980,65280800,30931296,13058840,5116200,1860480,620160,186048,48960,10880,1920,240,16 },{0,1477035,43365675,87629115,67070640,36292620,17091165,7459725,3052350,1162800,406980,128520,35700,8400,1575,210,15 },{0,270270,19505668,59182487,56959098,35606116,18722067,9043580,4114929,1763580,705432,259896,86632,25480,6370,1274,182,14 },{0,27742,6479044,31469659,39466726,29005990,17129840,9136140,4584294,2183480,982566,413712,160888,56784,17745,4732,1014,156,13 },{0,1221,1500345,12775620,21877581,19380636,13002066,7674810,4227510,2217006,1108536,525096,233376,96096,36036,12012,3432,792,132,12 },{0,11,220187,3784572,9424635,10418419,8084780,5322185,3218105,1846955,1016158,534820,267410,125840,55055,22022,7865,2420,605,110,11 },{0,0,17205,762970,3021360,4376250,4035615,3004650,2005200,1257270,755775,437580,243100,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,486,93114,673794,1373472,1566693,1349568,1006128,692064,453168,286416,175032,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,1,5474,93338,299754,449876,464828,395304,301848,216076,148484,99008,64064,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,0,84,6454,40117,87857,115514,116109,100590,79779,59829,43316,30576,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,0,126,2541,9975,18570,23535,24030,21681,18060,14265,10920,8190,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,0,35,455,1540,2810,3660,3935,3780,3350,2800,2275,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,0,1,34,130,274,390,462,490,474,420,364,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,0,3,12,21,30,39,45,42,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{32 },{465,31 },{4060,870,30 },{23751,11368,812,29 },{98280,91728,10584,756,28 },{296010,511875,88101,9477,702,27 },{657800,2098980,523900,76050,8450,650,26 },{1081575,6565350,2359800,438450,65000,7500,600,25 },{1307504,16056392,8332808,1930896,358800,55200,6624,552,24 },{1144066,31211851,23561131,6738655,1512687,290950,46552,5819,506,23 },{705432,48697418,54040294,19074198,5059978,1168860,233772,38962,5082,462,22 },{293930,61182660,101276175,44439955,13765500,3718890,892584,185955,32340,4410,420,21 },{77520,61680080,155530960,85976140,30956700,9610200,2691920,672980,146300,26600,3800,380,20 },{11628,49355046,195561642,138708474,58148075,20517606,6575805,1917993,500346,113715,21660,3249,342,19 },{816,30758304,200452032,186686724,91757364,36601884,13235724,4412826,1343034,366282,87210,17442,2754,306,18 },{17,14508922,166133452,208929592,121867832,54930808,22206896,8335202,2899248,922488,263568,65892,13872,2312,272,17 },{0,4969152,109926368,193074560,135994560,69555840,31284096,13073120,5116320,1860480,620160,186048,48960,10880,1920,240,16 },{0,1161615,56984865,145681070,126811895,74256455,37133460,17148495,7461195,3052350,1162800,406980,128520,35700,8400,1575,210,15 },{0,168168,22507576,88280556,97858124,66534664,37129456,18879406,9051770,4115020,1763580,705432,259896,86632,25480,6370,1274,182,14 },{0,12727,6494059,41965209,61570379,49594558,31143840,17442152,9163596,4585230,2183480,982566,413712,160888,56784,17745,4732,1014,156,13 },{0,352,1280928,15130192,30904368,30320004,21723196,13464528,7736520,4231800,2217072,1108536,525096,233376,96096,36036,12012,3432,792,132,12 },{0,1,154517,3936977,11988075,14881185,12418109,8603705,5420195,3229655,1847505,1016158,534820,267410,125840,55055,22022,7865,2420,605,110,11 },{0,0,9240,684210,3427810,5679090,5688210,4478430,3117510,2025450,1259250,755820,437580,243100,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,165,69510,670944,1604934,2016744,1851285,1444608,1030320,696096,453456,286416,175032,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,0,3144,79240,310464,524048,583800,522984,415296,306944,216832,148512,99008,64064,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,0,28,4389,35749,91042,131418,140679,127449,104706,80829,59955,43316,30576,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,0,56,1820,8876,18740,25760,27810,26130,22506,18270,14280,10920,8190,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,0,15,315,1315,2690,3800,4300,4295,3940,3390,2800,2275,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,0,0,20,100,240,376,468,516,520,480,420,364,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,0,1,9,18,27,36,45,45,42,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }},{{33 },{496,32 },{4495,930,31 },{27405,12615,870,30 },{118755,105966,11774,812,29 },{376740,617526,101934,10584,756,28 },{888030,2653560,631800,88452,9477,702,27 },{1562275,8730800,2973880,532025,76050,8450,650,26 },{2042975,22554950,11007800,2449500,438750,65000,7500,600,25 },{1961256,46535808,32746296,8959236,1937244,358800,55200,6624,552,24 },{1352078,77503261,79365341,26656839,6802411,1512940,290950,46552,5819,506,23 },{646646,104682039,157982055,65516143,19478448,5064829,1168860,233772,38962,5082,462,22 },{203490,114497040,259280175,134287440,46254075,13809390,3719100,892584,185955,32340,4410,420,21 },{38760,100601580,350978260,230735050,92093950,31205790,9613810,2691920,672980,146300,26600,3800,380,20 },{3876,69950172,390766692,332851500,154763835,59142269,20546676,6575976,1917993,500346,113715,21660,3249,342,19 },{153,37616274,355660128,402421518,220167612,94721688,36747540,13238325,4412826,1343034,366282,87210,17442,2754,306,18 },{1,15134930,262029364,405706292,265055772,128709040,55439448,22225256,8335338,2899248,922488,263568,65892,13872,2312,272,17 },{0,4343160,153985880,338135440,269063200,148477200,70869600,31363896,13074920,5116320,1860480,620160,186048,48960,10880,1920,240,16 },{0,827190,70648410,229997250,228664425,145027365,76854960,37372335,17159415,7461300,3052350,1162800,406980,128520,35700,8400,1575,210,15 },{0,93093,24515855,125359507,160861155,119197442,70551768,37651159,18919628,9052953,4115020,1763580,705432,259896,86632,25480,6370,1274,182,14 },{0,5005,6132269,53359306,92126970,81573648,54498886,32002698,17542538,9169602,4585308,2183480,982566,413712,160888,56784,17745,4732,1014,156,13 },{0,78,1024386,17096574,41939898,45747636,35056164,22808346,13643850,7754670,4232526,2217072,1108536,525096,233376,96096,36036,12012,3432,792,132,12 },{0,0,100298,3904472,14661020,20536065,18472465,13478069,8839655,5456495,3232625,1847560,1016158,534820,267410,125840,55055,22022,7865,2420,605,110,11 },{0,0,4455,582945,3737910,7126900,7778970,6486105,4710090,3168000,2032470,1259655,755820,437580,243100,128700,64350,30030,12870,4950,1650,450,90,10 },{0,0,45,48834,640836,1813338,2521332,2472192,2021085,1494504,1040904,697356,453492,286416,175032,102960,57915,30888,15444,7128,2970,1080,324,72,9 },{0,0,0,1652,64156,310352,592816,714420,675444,558096,425880,309100,217028,148512,99008,64064,40040,24024,13728,7392,3696,1680,672,224,56,8 },{0,0,0,7,2800,30583,91434,145642,166509,158004,134505,106911,81249,59976,43316,30576,21021,14014,9009,5544,3234,1764,882,392,147,42,7 },{0,0,0,0,21,1230,7605,18381,27510,31515,30870,27495,22956,18345,14280,10920,8190,6006,4290,2970,1980,1260,756,420,210,90,30,6 },{0,0,0,0,0,5,205,1080,2505,3850,4610,4790,4545,4030,3400,2800,2275,1820,1430,1100,825,600,420,280,175,100,50,20,5 },{0,0,0,0,0,0,0,10,74,202,354,466,534,558,538,480,420,364,312,264,220,180,144,112,84,60,40,24,12,4 },{0,0,0,0,0,0,0,0,0,0,6,15,24,33,42,48,45,42,39,36,33,30,27,24,21,18,15,12,9,6,3 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2 },{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }}};
const int N = 105;
int n, m, mp[N], cnt, ans, len, cc;
char s[N];

inline void dfs(int x, int t, int r)
{
	if(cnt > m || n - x + 1 + cnt < m) return;
	if(x == n + 1) return (void) (mp[r]++);
	s[x] = '1', cnt++, dfs(x + 1, t + 1, max(r, t + 1));
	s[x] = '0', cnt--, dfs(x + 1, 0, r);
	return;
}

int main()
{
	freopen("combos.in", "r", stdin);
	freopen("combos.out", "w", stdout);
	ios :: sync_with_stdio(false);
	cin.tie(0), cout.tie(0);
	cin >> n >> m;
	if(n <= 33)
	{
		for(int k = 1; k <= m; k++) cout << gg[n - 1][m - 1][k - 1] << '\n';
	}
	else
	{
		dfs(1, 0, 0);
		for(int k = 1; k <= m; k++) cout << mp[k] << '\n';
	}
	return 0;
}