QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#105379#4794. SalajDeterminantAC ✓1850ms3772kbC++14549b2023-05-13 23:36:012023-05-13 23:36:03

Judging History

你现在查看的是最新测评结果

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-05-13 23:36:03]
  • 评测
  • 测评结果:AC
  • 用时:1850ms
  • 内存:3772kb
  • [2023-05-13 23:36:01]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
int n,m,p,f[57][57];
void add(int &x,int y){x+=y;if(x>=p)x-=p;}
void sol(){
	scanf("%d%d%d",&n,&m,&p);memset(f,0,sizeof(f));f[n][0]=1;
	for(int i=1;i<=m;++i){
		for(int k=n-1;k;k--)for(int j=1;j<=n;++j)
		if(i>=n-j+k&&i<=(n*(n-1)+(n-j+1)*(n-j))/2)
		for(int l=j+1;l<=n;++l)add(f[j][k],f[l][k-1]);
		else f[j][k]=0;if(i>n*(n-1)/2)f[n][0]=0;
		int s=0;for(int j=1;j<=n;++j)for(int k=0;k<n;++k)add(s,f[j][k]);
		printf("%d ",s);
	}puts("");
}
int main(){int t;scanf("%d",&t);while(t--)sol();}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3588kb

input:

2
5 10 666013
6 9 10

output:

1 2 4 9 21 50 110 209 351 546 
1 2 4 9 1 1 6 0 7 

result:

ok 19 numbers

Test #2:

score: 0
Accepted
time: 245ms
memory: 3768kb

input:

10
31 248 8654701
13 11 331266209
33 517 52876477
26 580 675225807
48 2029 311070528
26 31 327981899
39 25 644128037
29 776 464963196
43 799 451592950
25 184 564388620

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 889882 7578514 4072343 2646977 4649285 7797829 7894657 8630011 5369867 7539674 4332126 8201689 8589675 2709364 4018535 3531401 5490003 4890382 334630 1280966 7295275 4971992 1680824 7744560 2450701 2716471 1097918 5...

result:

ok 5200 numbers

Test #3:

score: 0
Accepted
time: 316ms
memory: 3592kb

input:

10
40 824 539409846
50 585 610014589
3 6 769916263
13 93 240065572
6 21 893252985
48 1280 143950958
31 427 200372233
18 125 190248047
50 600 748232132
34 677 352494441

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 50940723 495678567 412844965 317555714 187443592 350487499 391954229 402095695 218373777 73614681 370006569 12603220 431899598 97996765 139693021 244174673 266862451 456657 4194...

result:

ok 4638 numbers

Test #4:

score: 0
Accepted
time: 184ms
memory: 3540kb

input:

10
48 854 607016811
12 120 289431820
31 606 963880288
30 51 694250530
7 21 992868166
22 403 776349308
36 275 187274190
34 348 999649437
41 1629 577421904
8 36 984053206

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 522743604 157643742 545167147 175112414 165755482 423528847 80343671 166467655 592104336 105467013 56931183 297982918 72516092 547353790 506319622 308311520 417713371 493782600 ...

result:

ok 4343 numbers

Test #5:

score: 0
Accepted
time: 284ms
memory: 3592kb

input:

10
4 2 328716341
13 9 54650583
45 172 183200845
47 2000 21967554
9 68 244475608
39 580 188361963
46 928 167521522
32 50 635069323
43 497 187411488
38 17 501177872

output:

1 2 
1 2 4 9 21 51 127 323 835 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 34361533 30555345 78313432 66561096 21700176 93836492 90319134 172047029 29642286 176061921 45879387 10667798 131348190 177476193 72316088 10477536 7428572...

result:

ok 4323 numbers

Test #6:

score: 0
Accepted
time: 142ms
memory: 3772kb

input:

10
31 237 509200942
46 806 411646075
8 46 410603898
16 53 207952679
26 574 640802950
27 562 552565617
9 61 876206762
29 629 132413125
43 632 381102789
7 3 795847568

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 111358531 137522145 386986487 209771376 192038096 269293873 14486457 218731525 457086885 303970760 147973007 440517990 351950964 46684902 310133642 121113938 445063894 431195896...

result:

ok 3603 numbers

Test #7:

score: 0
Accepted
time: 135ms
memory: 3528kb

input:

10
38 846 136367665
19 303 844177132
5 4 216084622
38 675 328942914
13 11 443808880
5 6 568625933
21 211 583830322
16 115 987525295
19 55 222893467
40 1245 733398812

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 6179894 128027893 38819095 56271502 43136611 32697456 51072027 62589084 134339084 17144956 27198786 66807667 101189653 82204645 20225088 104509848 68171646 18960635 19869818 52176344 102067430 9425...

result:

ok 3471 numbers

Test #8:

score: 0
Accepted
time: 404ms
memory: 3596kb

input:

10
47 1177 256962356
34 169 642155942
45 159 313533055
22 97 181831118
40 313 74123453
18 106 435002674
46 1698 806413602
5 1 283545076
48 2084 358823753
3 2 708993134

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 143800867 101910991 109179525 49720041 230545232 30463698 140732205 159742469 149109831 89599719 42554963 106968139 107913118 43596380 138493903 189399515 247838053 57791101 122745473 153...

result:

ok 5806 numbers

Test #9:

score: 0
Accepted
time: 211ms
memory: 3600kb

input:

10
32 601 413105496
8 41 605573562
7 29 23022845
42 159 52337248
39 1153 814042096
38 494 631375577
24 441 577229991
45 1639 178695424
4 11 404796490
8 50 998016736

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 303549423 300989325 368187085 57277724 301205506 231213721 110187077 348093643 401726943 347177619 220281914 378606644 105534776 218850594 254239602 251724718 227730726 14719270...

result:

ok 4618 numbers

Test #10:

score: 0
Accepted
time: 488ms
memory: 3592kb

input:

10
45 1306 532336249
49 1642 684346052
25 361 79987143
6 11 316897899
43 1170 903383328
39 1466 679221699
37 103 968940008
15 206 818005186
29 423 530930425
46 1182 925815805

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 65087917 531046552 526022517 117678524 77706689 412141099 187867194 297509399 64059270 200365381 57344978 350386527 513925235 498530463 129698180 76007503 26676684 529351202 180...

result:

ok 7870 numbers

Test #11:

score: 0
Accepted
time: 316ms
memory: 3568kb

input:

10
8 21 227991343
5 9 137734388
47 142 223233581
33 734 944278670
2 1 23560027
50 2369 708140724
42 1090 372448362
35 1030 837627960
25 488 330085593
15 199 581994202

output:

1 2 4 9 21 51 127 323 834 2150 5286 11760 23256 41667 69597 110561 169004 250470 361790 511290 709020 
1 2 4 9 21 50 110 209 351 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 177529642 13592510 67457663 114059261 221190242 10391815 ...

result:

ok 6083 numbers

Test #12:

score: 0
Accepted
time: 311ms
memory: 3700kb

input:

10
17 195 689522608
39 1469 17969850
47 1514 89310549
24 9 928841375
13 133 758320921
2 2 529730181
9 2 519589186
19 158 165447530
45 1311 883851056
35 975 64352040

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536381 18199129 50843923 142333979 397345233 403254545 143032583 372521015 349550279 411919751 507773343 518007471 622893874 396100602 88442183 248948543 175582427 552080135 533917083 403801299 439155885 665332059 25403932...

result:

ok 5768 numbers

Test #13:

score: 0
Accepted
time: 208ms
memory: 3508kb

input:

10
40 495 241758396
2 1 518027019
38 828 555827999
25 569 644329940
23 104 343520353
17 223 844329924
31 905 267913387
41 1343 675910766
49 415 98487101
29 660 102170425

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 159004827 162726831 49868649 98341849 43428500 238495606 111057649 225922649 241531291 176158395 65951643 153540339 193601206 89105228 158989111 217758835 98841593 11686009 142465629 1333...

result:

ok 5543 numbers

Test #14:

score: 0
Accepted
time: 317ms
memory: 3612kb

input:

10
12 53 629232538
43 343 427439414
24 229 245807167
35 940 855792472
49 2098 417433677
22 238 7011437
42 1667 364588782
42 25 64999402
9 9 838335002
30 788 175010722

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41834 113554 308386 822757 2088164 4885101 10384309 20176871 36463440 62408580 102518364 163039044 252475160 382258396 567576892 199162978 561469494 429553919 475528979 124584881 74524080 411152647 611925989 179464575 534261996 615894492 35957948 344365850 4...

result:

ok 6390 numbers

Test #15:

score: 0
Accepted
time: 196ms
memory: 3568kb

input:

10
4 3 823218312
7 20 361892902
30 164 21157668
2 2 205428398
50 1474 727428380
19 275 476049058
36 694 394120307
27 573 621211401
7 2 408334044
27 200 197034032

output:

1 2 4 
1 2 4 9 21 51 127 322 805 1862 3808 6936 11628 18411 27930 40964 58443 81466 111320 149500 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 8536683 15601551 19925199 8404011 19077597 9078265 5567192 13818202 1086433 16305413 11555911 14598134 1782...

result:

ok 3407 numbers

Test #16:

score: 0
Accepted
time: 206ms
memory: 3600kb

input:

10
34 695 480228627
8 3 447199901
5 4 281952301
41 396 882371595
5 4 463016900
32 736 498248191
33 777 240661474
38 191 998343798
8 12 497433001
45 1852 60968910

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 169303161 311356035 399287215 217701245 13021498 84282718 180201857 257503393 328199778 215962929 380604237 362932255 240089230 427779751 453059348 318746398 329527410 369532191...

result:

ok 4670 numbers

Test #17:

score: 0
Accepted
time: 377ms
memory: 3524kb

input:

10
13 150 333227102
44 678 897934166
46 1998 161023921
28 184 377235617
8 25 118760552
37 100 389243769
46 346 837625208
43 884 798287694
24 389 978932466
48 1215 927754193

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113633 310479 850525 2309203 6061458 14909375 33608198 69131062 131186926 233646504 63458446 315933606 31737798 266087588 94801798 285822524 307706009 5115786 276819439 90791857 166949510 332215507 212138862 260751308 130444588 47665970 197084030 11477...

result:

ok 5969 numbers

Test #18:

score: 0
Accepted
time: 158ms
memory: 3592kb

input:

10
38 953 882624094
38 292 28047290
5 16 107563361
38 1166 656463874
39 64 305925119
5 9 433413594
33 757 688476595
10 76 685252923
41 646 818499697
12 11 415820849

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 247136321 544855515 217161561 73719750 632597094 606616119 619393661 99338449 33414827 465398823 175587815 439557950 874289562 37209453 116370559 128679137 140961308 504227364 7...

result:

ok 3990 numbers

Test #19:

score: 0
Accepted
time: 299ms
memory: 3592kb

input:

10
7 18 255318148
45 309 515326606
48 1983 480126673
36 569 5120134
6 23 559357360
40 1172 140810094
18 208 845181903
3 2 334863937
28 490 191423029
34 552 215405669

output:

1 2 4 9 21 51 127 322 805 1862 3808 6936 11628 18411 27930 40964 58443 81466 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 99107203 100768161 282850199 418814782 346721356 346655991 86534717 414957653 231781811 168573679 2...

result:

ok 5326 numbers

Test #20:

score: 0
Accepted
time: 103ms
memory: 3592kb

input:

10
3 4 351323783
41 378 444908325
21 48 412770520
32 236 10480760
44 917 752932248
20 56 461212026
3 1 888190498
24 409 188119190
22 365 250872733
28 8 353757838

output:

1 2 4 7 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 239943765 78369522 145236001 310043951 42807502 251090434 235079279 60211336 28042416 375332682 312367008 370294720 248984978 49689913 100580041 198033590 86113099 2410...

result:

ok 2422 numbers

Test #21:

score: 0
Accepted
time: 160ms
memory: 3520kb

input:

10
36 1032 395661998
14 147 786468828
8 1 968613712
39 1202 687707421
11 2 737915557
19 301 4655690
20 182 718726947
39 1220 417713678
20 50 342563116
30 865 449076459

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 5101225 338436419 27431813 338838545 347450604 205965170 300729259 249787829 391161789 241016955 332087137 245454287 229679516 165666624 88685971 51043828 215772123 374179475 373725129 35...

result:

ok 5002 numbers

Test #22:

score: 0
Accepted
time: 98ms
memory: 3516kb

input:

10
19 46 736807180
18 277 650581418
21 232 971092818
29 751 650407566
9 62 131394183
44 949 413448298
19 280 12893526
24 479 249596783
29 541 696108637
5 16 209273508

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852018 142547367 400750831 392550426 237586392 97204225 357496729 163968320 726792656 64841163 651516300 440725101 229801400 267122285 131160205 403170740 57091320 42146035 633535095 392816750 156367210 5...

result:

ok 3633 numbers

Test #23:

score: 0
Accepted
time: 82ms
memory: 3600kb

input:

10
11 17 838916855
7 37 310968431
17 95 558008685
36 685 414000059
19 166 197964901
16 192 553584327
21 142 250677603
32 570 980995299
28 664 173748502
45 385 796608335

output:

1 2 4 9 21 51 127 323 835 2188 5798 15510 41767 112046 291357 706992 1558557 
1 2 4 9 21 51 127 322 805 1862 3808 6936 11628 18411 27930 40964 58443 81466 111320 149500 197730 257984 332486 423710 534130 666220 822454 1002832 1207354 1436020 1688830 1941640 2194450 2447260 2700070 2952880 2952880 
1...

result:

ok 2953 numbers

Test #24:

score: 0
Accepted
time: 269ms
memory: 3616kb

input:

10
10 32 653268426
40 495 983032232
43 766 700582018
4 10 551265471
22 236 646118173
27 528 579196581
46 1509 537574411
35 569 976987542
38 1297 410607005
6 11 172852135

output:

1 2 4 9 21 51 127 323 835 2188 5797 15454 40711 102025 233794 482130 904475 1578720 2614755 4162080 6418425 9641775 14164644 20410896 28915436 40347120 55535260 75500128 101487892 135010447 177890635 232313380 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 1819...

result:

ok 5453 numbers

Test #25:

score: 0
Accepted
time: 54ms
memory: 3588kb

input:

10
36 789 233862037
4 5 178022925
28 600 12380981
6 8 805164509
7 36 206618435
24 95 170565075
10 78 314970041
29 107 383013623
19 270 842356391
18 56 260005948

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 166901186 194312267 152521316 156645095 178856443 42817258 119927316 200934923 14806665 108547531 69182247 129485196 146103592 150634275 34577402 51890773 78910344 164989775 137459972 203...

result:

ok 2044 numbers

Test #26:

score: 0
Accepted
time: 298ms
memory: 3564kb

input:

10
4 5 486305785
13 28 91613949
31 822 871700302
4 1 311933049
37 1317 778500501
44 1103 538869578
21 28 102536403
15 15 656849717
12 107 221283366
49 1821 486870125

output:

1 2 4 9 20 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113633 310479 850525 2309203 6061458 14909375 33608198 69131062 39572977 50418606 30229752 7863065 23665665 41558863 45428838 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 ...

result:

ok 5247 numbers

Test #27:

score: 0
Accepted
time: 124ms
memory: 3704kb

input:

10
33 878 255567263
35 12 992540745
8 51 482587685
25 415 319173102
28 399 700432517
15 118 845144790
32 594 892855798
43 1065 157041915
23 83 994001832
28 107 415489119

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 145195960 107491363 125920641 98548296 113092176 171102847 247093390 60032880 163277628 150170446 42167947 54502271 50046364 87417721 164880681 254502132 192075615 124430875 152263773 163...

result:

ok 3722 numbers

Test #28:

score: 0
Accepted
time: 173ms
memory: 3520kb

input:

10
3 3 892624008
25 395 514812623
43 373 984263961
26 108 112866388
22 95 436719587
10 85 744741942
46 13 910102730
50 1276 320701031
30 50 184319265
14 57 658516319

output:

1 2 4 
1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 100135169 103852059 291587910 443999948 419192632 38942713 161864126 498123527 42572234 208731612 329531352 399930163 44288588 435072165 329553248 3891493 449854951 23926...

result:

ok 2455 numbers

Test #29:

score: 0
Accepted
time: 286ms
memory: 3596kb

input:

10
46 937 445329947
5 20 235919650
8 55 236857287
11 14 844396592
21 207 719240661
39 1210 485281111
26 555 672415800
49 1607 216370778
43 43 806132289
2 1 209612934

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 239100521 75418168 136803561 286011497 418991441 54192960 117965478 233043194 321294727 85964971 256956861 60909400 151234870 60379324 89588393 395676524 381521592 120332163 292...

result:

ok 4649 numbers

Test #30:

score: 0
Accepted
time: 155ms
memory: 3540kb

input:

10
21 104 486801487
6 25 173448237
50 946 918641583
8 13 559176697
37 1191 215911540
20 272 520239484
7 20 818926686
36 103 997529766
32 302 890629903
5 4 371933773

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763222 156157208 271900657 280259675 339173082 204902918 2675215 482786638 63154979 114263444 374406425 402119937 444081733 365081064 188674571 76263267 282256966 352073231 324110802 2...

result:

ok 2980 numbers

Test #31:

score: 0
Accepted
time: 78ms
memory: 3584kb

input:

10
35 527 359002677
17 147 418107599
25 90 602379870
21 129 894614835
46 592 82376312
11 105 345907995
35 103 875890294
29 273 753460885
22 322 55239337
14 159 279322971

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 41760546 52752384 320706381 68335576 180628409 130229371 160728226 311359748 20814355 301440519 316449660 232488681 149081170 247795166 283326279 209282747 300435882 131240619 223294752 1...

result:

ok 2447 numbers

Test #32:

score: 0
Accepted
time: 214ms
memory: 3612kb

input:

10
40 269 839712427
41 1638 362113162
24 251 279733714
10 57 332975210
35 3 744532760
11 8 107784200
24 461 867362583
28 387 109791600
41 1224 215796362
39 1134 652072106

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 290047988 673590516 646278231 478445666 792504080 614308740 66098940 326656244 345861342 221045496 244178657 166195744 401989128 524341100 506717341 100275449 803384212 80907178...

result:

ok 5432 numbers

Test #33:

score: 0
Accepted
time: 77ms
memory: 3596kb

input:

10
49 361 384859852
38 89 330743276
13 117 522987128
31 544 460889338
29 347 500707451
43 85 109106084
13 11 363565842
10 34 284574445
32 642 645813565
14 91 857109976

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 15903371 360040711 113848981 191625905 269068244 269260774 198958129 288893045 153523891 136325187 103264899 131759203 279943710 89091180 377515631 262195139 89864081 47981993 150442429 2...

result:

ok 2321 numbers

Test #34:

score: 0
Accepted
time: 131ms
memory: 3616kb

input:

10
33 805 944812814
20 50 734935826
30 632 178192423
31 178 912193835
13 26 53669851
15 137 596981945
39 585 511466433
40 97 699649794
15 4 925427633
41 1075 317408642

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 184947601 358289355 540087175 159872498 257186124 164459129 400337637 501657267 589373989 414778649 35044137 262996399 933237625 654632211 126914457 75533287 568649497 535105695...

result:

ok 3589 numbers

Test #35:

score: 0
Accepted
time: 344ms
memory: 3772kb

input:

10
47 1853 854674950
45 506 165471762
25 274 808872088
46 1490 634292233
8 40 70417450
28 648 828718238
2 2 931217982
33 703 112553511
34 829 959117393
3 3 84200988

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 400763223 275085465 628702947 496653001 29569976 360402052 337265359 598369529 1020511 79910691 658311807 258416283 738751270 74154878 271968913 70926841 677579165 43589449 384353847 6647...

result:

ok 6348 numbers

Test #36:

score: 0
Accepted
time: 1850ms
memory: 3592kb

input:

10
50 2450 330935663
50 2450 306856390
50 2450 663109790
50 2450 313827265
50 2450 341027331
50 2450 903644493
50 2450 896799364
50 2450 470703911
50 2450 393705133
50 2450 970756327

output:

1 2 4 9 21 51 127 323 835 2188 5798 15511 41835 113634 310572 853467 2356779 6536382 18199284 50852019 142547559 69827560 136953426 214306830 108139600 187772425 201926942 195681845 44205407 16455684 302400899 185127418 285575295 146379975 39569110 280182162 266539005 223325571 291614132 168074666 5...

result:

ok 24500 numbers