QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#646955#1203. Copy and Paste 2Grand_Elf100 ✓68ms6140kbC++17664b2024-10-17 10:29:292024-10-17 10:29:31

Judging History

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

  • [2024-10-17 10:29:31]
  • 评测
  • 测评结果:100
  • 用时:68ms
  • 内存:6140kb
  • [2024-10-17 10:29:29]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;

const int N = 2e5 + 5;
const int K = 200;

int k, m, n, a[N], b[N], c[N], pos[K];
string str;

int main() {
	ios::sync_with_stdio(0);
	cin.tie(0);
	cin >> k >> m >> str >> n;
	for (int i = 1; i <= n; i++) {
		cin >> a[i] >> b[i] >> c[i];
	}
	for (int i = 0; i < k; i++) {
		pos[i] = i;
	}
	for (int i = n; i >= 1; i--) {
		for (int j = 0; j < k; j++) {
			if (pos[j] >= c[i] + b[i] - a[i]) {
				pos[j] -= b[i] - a[i];
			} else if (pos[j] >= c[i]) {
				pos[j] = pos[j] - c[i] + a[i];
			}
		}
	}
	for (int j = 0; j < k; j++) {
		cout << str[pos[j]];
	}
	cout << '\n';

	return 0;
}

詳細信息

Subtask #1:

score: 10
Accepted

Test #1:

score: 10
Accepted
time: 0ms
memory: 3732kb

input:

10 777
thejapanesecommitteefortheioiisanonprofitorganizationoneoftheactivitiesofwhichistohostjoithejapaneseolympiadininformaticsjoiisacompetitiontobeheldannuallytoselectandeducatestudentsenrolledinhighschoolsorlowergradeschoolsinjapanwhoaretalentedininformaticscomputerscienceaswellasprogrammingthose...

output:

ecmnalapea

result:

ok single line: 'ecmnalapea'

Test #2:

score: 10
Accepted
time: 0ms
memory: 5644kb

input:

200 2000
mpxlemtbejfoneeijajipgsfabimjymoypfaqjbxbqgukbuzlrkzjgbqaogpzzbkdcxcjluljbspvirzmmevqinfdhwfdntuqfztpdrrzvmrmfowvjeotveqdvhqootplselzsztegtcfxanxkfcvajffgzpwduyvffwdxgkpdbvpnzxfwlhufepnaogxjkfsuqqjaezwcpqaeoxwhzhxicnbtjrhuyuipikhgmobtrrccqgaqzbgjexpxenoliwzhdswbkatnvpzwoeajhijeoeuodxlopxmcp...

output:

mjmnacgqacwmjgjdqmnangqmnvvnwmajjdxngqmgaxngqmnaaxffugvnwmajjdxngqmgftngqmnvnngngqmnaxffagjjdxfxftlvngqmnafngqmnvnngqmnacgmnawmjacgjfaxngqjacgxcwmjgjdqmnangqmnamnajmnafmnajmnawxffagjjdxfxftlvngqmngqmn

result:

ok single line: 'mjmnacgqacwmjgjdqmnangqmnvvnwm...najmnawxffagjjdxfxftlvngqmngqmn'

Test #3:

score: 10
Accepted
time: 1ms
memory: 3680kb

input:

200 2000
hnhehwrziwsqycxuxyhhaampeyomalneexfzjjtmepuarqicwjbiewhcjvfrzlcecarmmkjmlkbtvkcaorickqtpknbcfmkbdbubhpvqqtumhoevopsutvzveudrvbzpgbzmssyibgzgcqwfaaixegdnrrubogunfjnwgjnbniyurgozyvlfoltyeazlypfjpcpqmqxosvllbvyswjlngkwmwjlytbjlidntdmjblhwdgqmlucjzoywxnailoucyvpncemslztcaefjddhdquvytuuvddboiopf...

output:

ovhvmezunvzuhutovvuonookvtvvvdzzvvvvvhtoovvooovvoveovzkpvveovqvvkvozutmzozoevmvvhoevetdopovpvzoueozevoeevupkpoeeovhooozuzoovoeuvvezveovmeuvuzdvoeuvpoozoeevvuovouvpkzookquovvooeeovvvoozptzvezppvpkookue

result:

ok single line: 'ovhvmezunvzuhutovvuonookvtvvvd...uovvooeeovvvoozptzvezppvpkookue'

Test #4:

score: 10
Accepted
time: 1ms
memory: 3740kb

input:

200 2000
guqzvnwkzlydfghukcdadwfgfvcykzvelfljbdlglplonplclousncbkdfsnmlxnsaupexkbgccgfetzbwqzhesxpbqnkingwmhnttikwqpngagirckfsgynbnawpshxmxowxsolfbaxvbhximamqidltsronyzslevgyslnrhhtsiixwwwplhshgfruxtuuvzpgohdatpmciefnrrdvpwqoxghdytevkzbbbsfgfzxxvzfthzavtezaoyjacfhidngtrwfadpoouprqcgfbwzjdopuzqwqdati...

output:

guqzvnwkzlydqzvnwguqzvnguqzvnwkzlydqzvnwguqzvnwkzlydqzvnwkzlydfghukcdadwfgfvcyguqzvnwkzlydqzvnwkzlydfghukcdadwguqzvnwkzlydqzvnwkzlydguqzvnwkzlydqzvnwkzlydfghukcdadwfgfvcyguqzvnwkzlydqzvnwkzlyduqzvnwkz

result:

ok single line: 'guqzvnwkzlydqzvnwguqzvnguqzvnw...yguqzvnwkzlydqzvnwkzlyduqzvnwkz'

Test #5:

score: 10
Accepted
time: 1ms
memory: 3740kb

input:

200 2000
chcdaqasvphzbtexjxqpzuxwsryfwxkmehlblddzcbwnvkfwmzubexrsgzxafbizehzksxyzqgtgigijyniznapdpcfdptxtwnlpkwsydapfholsjmjnbhdrutiebpfreuyyaqidbdpmckqmszgxryebzmblgpwkflichgdgwenjirvrndskgdixjhbtmbbhulwbrgsdkdssanetygzzillkzgrbzazjxbumokogwofikqwzxtraiebwljpmlzasbaxpnxziqyzvirwwofxdrwjkucqbtaoincs...

output:

cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc

result:

ok single line: 'cccccccccccccccccccccccccccccc...ccccccccccccccccccccccccccccccc'

Test #6:

score: 10
Accepted
time: 1ms
memory: 3612kb

input:

200 2000
nbolrydnxwwzdrgvebthqknbmvgondmqurdjrywyhoyntujngqozcmmguqubyzifhvfgqgdoigsjuaxtiliyvwdwtvattdqwjnpahpogmhpyayknbzbzqxazusbctpnschwiyiyiofmbblsuehxbhozzvidcxkcaspkaosiwrowlqazgsyaroxgqmrchveqnyzmrlrekqjluefnrsruydacgmpktgtothuczskmeryvitmyvddalwipsxmdndoklaxlnwkxaqaqittfsllcdmckymoszjmtfynw...

output:

wrocyyjynwiaiimjjhurtnurgzukxrgqiaplxkiioyvhmwzyijhsqbakkgrqrsoalmrewnvthefabgmubrkknixlymxahveqawkciineqjiymerwxuewexqrminxxqogfqzplsoklizqpcfbrtswasqpksdaqzdcpqenlwyiqssbvbmzqwcdkcnyyfzuefewckemwntq

result:

ok single line: 'wrocyyjynwiaiimjjhurtnurgzukxr...ssbvbmzqwcdkcnyyfzuefewckemwntq'

Test #7:

score: 10
Accepted
time: 1ms
memory: 3700kb

input:

2 2000
yl
2000
0 1 2
1 2 3
2 4 0
0 1 0
0 4 3
0 10 11
0 19 18
12 13 28
19 20 19
9 17 40
8 38 2
59 69 25
59 63 43
19 91 26
43 52 125
90 105 64
8 91 80
231 240 106
46 81 246
19 229 279
209 274 35
76 310 526
273 479 165
487 535 310
768 876 62
38 105 780
154 664 361
227 510 270
1306 1966 935
467 685 834
...

output:

yy

result:

ok single line: 'yy'

Test #8:

score: 10
Accepted
time: 1ms
memory: 3704kb

input:

200 2000
jarlmnjmjxrksrptyfmzprugaxmymnrznfnjnmuvugtgxqaramzdvwusqnszyjyvzpmeqxhqtdpxdyudziwkthnbjqszgqzahsmdzaskndgzppyxlzqtjvlxbavldwyieglzhfbzegceumfrcdlpghlnnilcvfwltccktcqkzplqzgnwgfllqlofwgwvduedzrhlkwhv
2000
167 193 31
6 89 92
52 133 84
178 329 189
198 377 405
129 597 605
38 613 20
82 1205 84...

output:

ztgfptgzpnpfprnrzpydzryfvnfgpztfqtntygultfgtfztgryzfynpffnydgupfflpldvfypnpglpggunztrvyyfgppvtygplttypgqpygrtgvtpnpyttngpzzzyfyzqnftgtpqzgtpqftyzpynnnffzgggrntrnggfggufgpppyutgpykttfrzutvprpgytpfyfgqn

result:

ok single line: 'ztgfptgzpnpfprnrzpydzryfvnfgpz...pppyutgpykttfrzutvprpgytpfyfgqn'

Subtask #2:

score: 90
Accepted

Test #9:

score: 90
Accepted
time: 59ms
memory: 6112kb

input:

200 536870911
cfoactihjgtajhquhzwzycprbguslqxpfkhhitbaojysegaftymynxmtnhwqnzxhiravpwtvoezhhjpyaukwvpydxyujxehhyjesbgvyryahisfqhvmzsyhvbcouucqxgzzzkfrextdxpukqtzvosxvlshcxhjbhawiorjabyuzjublpehslwthgncqriemqcswyfxiilbirllgsimmtibrcnzflmqxeospyhmwwqhmyzwgoludgwazvsumznzzoklvevbjbvmbbkuqdzvhdhyhhmzdlvp...

output:

gywbpedljxancupeqvprflupxequkdikphhyrnkppovqwunyakfxjxfmwqaepbretxpxelsspiaqkxdoctaoisqqfzrymchsplkczgaqtfadbpwkyahhwgqfefetgdxawbcutzrkyhjwrhdceavsbdffwqkguxzzjowinxrdzhzlludbglxrewfqtvkqyhnjafrydmsq

result:

ok single line: 'gywbpedljxancupeqvprflupxequkd...hzlludbglxrewfqtvkqyhnjafrydmsq'

Test #10:

score: 90
Accepted
time: 50ms
memory: 6036kb

input:

200 1000000000
nvcvtxefzhsqkrziprkynmohtiufypxmwsjtqaxnrordosnrpvwikvsycjrulthvgahihtuhbkbileumuonyrwyvxcvftileifraspeicqmdhqalvvipjcfzjgsfuqthmizpgwytaadcmxibdrbzjktsmsfeobkuyzjkyzcbavrtnslacdypsrkpeawjmfucosjxstkdjsjubrvfdsyckfqwwboynmeynyrdzimcwrhyixxudjbrfwjggigpuhynbzzierivwnzsnjhmdbegwerryscuw...

output:

nvcvtxefzhsqkrziprkynmohtiufypxmwsjtqaxnrordosnrpvwikvsycjrulthvgahihtuhbkbileumuonyrwyvxcvftileifraspeicqmdhqalvvipjcfzjgsfuqthmizpgwytaadcmxibdrbzjktsmsfeobkuyzjkyzcbavrtnslacdypsrkpeawjmfucosjxstkd

result:

ok single line: 'nvcvtxefzhsqkrziprkynmohtiufyp...vrtnslacdypsrkpeawjmfucosjxstkd'

Test #11:

score: 90
Accepted
time: 53ms
memory: 6044kb

input:

200 1000000000
gpmcuhsrdqpsltsyjlenioihvdmrvaqcawdkhqhqcddnbhfkovtxdfeibwqirnsftszgoyfmrdwqvurnqpxvxccdowaujpipnpgqsbshzsgqudswcpwntgougtiqfxrfhrswjwfovwbmjaorgbsqkwruidmewsqpgfnonlxqskicpxoydgqpqldsvcbcpjfufoobxjlkbdnzeclqhwwazfulnxkxrxnntuqszyzdspmgappdpnljbhxiulazskoppzxoqkqiitsxcgmtelgwvpbwmkmsi...

output:

gpmcuhsrdqpsltsyjlenioihvdmrvaqcawdkhqhqcddnbhfkovtxdfeibwqirnsftszgoyfmrdwqvurnqpxvxccdowaujpipnpgqsbshzsgqudswcpwntgougtiqfxrfhrswjwfovwbmjaorgbsqkwruidmewsqpgfnonlxqskicpxoydgqpqldsvcbcpjfufoobxjlk

result:

ok single line: 'gpmcuhsrdqpsltsyjlenioihvdmrva...kicpxoydgqpqldsvcbcpjfufoobxjlk'

Test #12:

score: 90
Accepted
time: 61ms
memory: 6076kb

input:

200 1000000000
rfaxlloptroimrlqrnkwxwdnnvqiizgtdybovppnfygydxioqmnnwpsnasngvxijrzsdklgkqfqhrlijubqpvlsbcajetzusffjixkdxqmkedpnfehovwausyjgxtbavjmuwfhsfcxzlifygutcxxlfvuadxrulicuoogjpkwduuqagzvuobifwngilcdilsvmjierfhtsqykyuzaaibvtxdsrbeujmnswsvhwvxgtlsnygbrehaqxzngpsrtwfkizduxaxmlcqaxpxekjndehfcsbhhz...

output:

jkurlccfwncveuonzrwyedybfkvksyvbxetjwspdllzorkvclmqkpctzvnwflyxfsyrweffwhdtpjdazxsszuszioayexhgkknzlnegvmlkvsxlmnohautzkhxereivprdrsnywsksrceyhxuhxxstahxuydvsulkwolqxvjuhngfhmvliltwxfoarmqmuhfbkulfrhd

result:

ok single line: 'jkurlccfwncveuonzrwyedybfkvksy...hngfhmvliltwxfoarmqmuhfbkulfrhd'

Test #13:

score: 90
Accepted
time: 51ms
memory: 6136kb

input:

200 1000000000
ujktmosnsjxnmfwyrjyqyykgctfwqwcnuhwmowdqqyowipikxyokuysjwkffntlfmexcytgwwvhrhlinaeagolpccdglnpmzfserylhomwcdddwbdqclenxwkqzvnqojbmtjgazrmdyevcscjkhjmubuqyiakalpinelmxhprkvmvjnmaussvxehnnoiuqcuibbntpyuiipapcfeyoaipvrkvxqadyurvljsinwhxfxomyfhbzvryizdkbodyolwkckiflrjfphbhbdbbixdpsxcqcujb...

output:

ujktmosnsjxnmfwyrjyqyykgctfwqwcnuhwmowdqqyowipikxyokuysjwkffntlfmexcytgwwvhrhlinaeagolpccdglnpmzfserylhomwcdddwbdqclenxwkqzvnqojbmtjgazrmdyevcscjkhjmubuqyiakalpinelmxhprkvmvjnmaussvxehnnoiuqcuibbntpyu

result:

ok single line: 'ujktmosnsjxnmfwyrjyqyykgctfwqw...kvmvjnmaussvxehnnoiuqcuibbntpyu'

Test #14:

score: 90
Accepted
time: 51ms
memory: 6140kb

input:

200 1000000000
fyvjajjjohnynvzkafwwgrfknrxkwzxsaazgwyvterlrbskqmoufeurbmpqzuxxhscxnjosrpzmbpiqgxakkvtrxghwncnalhrqddfqhvkvtrrlredihmtuuawxpnbyxugpwsqdyfcrljvfflbdbapolybovjhgbhyomrvafdodfrlctshykldmzkqvgweadydflgcxmelnrspzcpbhidypmyhfaqdbtsfmauimpzfnuxeoawtvkolarokkpcuswbxbopjujmbaclogcwtbhersomkymy...

output:

fyvjajjjohnynvzkafwwgrfknrxkwzxsaazgwyvterlrbskqmoufeurbmpqzuxxhscxnjosrpzmbpiqgxakkvtrxghwncnalhrqddfqhvkvtrrlredihmtuuawxpnbyxugpwsqdyfcrljvfflbdbapolybovjhgbhyomrvafdodfrlctshykldmzkqvgweadydflgcxm

result:

ok single line: 'fyvjajjjohnynvzkafwwgrfknrxkwz...odfrlctshykldmzkqvgweadydflgcxm'

Test #15:

score: 90
Accepted
time: 45ms
memory: 6140kb

input:

200 1000000000
qnodkqkbctrxixyizxamouumtlnxihglhcdcahuxickazuphgtrtdbyhcvpenpjznwybvgluqmwoociuufundcxbsjxvxewmwuldwvcbzbsdvesyeshfodemnjagzirkegqzpdsmgjwrpnmilxovlofrczyowtkcdzukzthrqtzcyocetvddftqblxkyvhzjtjqnnqqefmngiakrlohudoysakuamuvktsaqtbszqitkkssmkkfeipoucoosqckjvxtgzriammqyyvvfbmgdsbdzyxeic...

output:

isqayjvfikujhkjcxxfidepoujdhpeuizscicxuuilnrrqidqozdoipnzxvwprevynmdfdnvoryxxahhbpjoszyjuphpwdtvixbscumfabzvspvgyzuhgklbavfnfzcahljrldwucbdujdmekxzmfhkkfxqsznlnnpjdcfszxgiscmomqbzbwztdpyxxinjnctmoxxbx

result:

ok single line: 'isqayjvfikujhkjcxxfidepoujdhpe...giscmomqbzbwztdpyxxinjnctmoxxbx'

Test #16:

score: 90
Accepted
time: 48ms
memory: 6140kb

input:

200 1000000000
bcztylbxyrhijnbisxyeonpoczfpgkxodpqaihomkxrxgbvzhhnejzrrkogaatxbvymisttbvmdmwxazjtebkgxkytfrygmqedvdljtsytxfjyzylnrbqdnudxiwnpvszucidpizfuvslablnokvvbmcmuentehkqeypszutelrncedbxixttjwpokbktnnirtyhapnoljhzrzetezwyvvkejyxexjoiigdijywvmcbyxejjlqflastcifwauylxqyymbrzubmbvgiwgyhshzesdklyvh...

output:

mnodtlvmmstioyhfomaghfsmoxlknhljneusnubhtewaxuuvkdkzgtujtkfwphfhlszjjgrmowdsceipbvifafprtcfcrajwvcrlnoowetsyklxhcapbcfazkonrztwnbixnklhnvnklzohqhyspkfbwpdbpyrxmcuychvtwsavatbvinynbstrehkufbuxmolciuvkf

result:

ok single line: 'mnodtlvmmstioyhfomaghfsmoxlknh...avatbvinynbstrehkufbuxmolciuvkf'

Test #17:

score: 90
Accepted
time: 68ms
memory: 6000kb

input:

200 1000000000
ttxwtebzizfnxrtdfkhcsptuqinkayrgldwstbquagkuxblnncrcxldwblmktbfggjxbrwmbkslbzjikwykjrauxskknkcjmaiwptckbvbbfknryjwajxviwzudpqalirvikjlceqvkzfpznqkdckxfpmmizpbklpulumbgpxzbxmubpqitbrmqjvqzricdfoztfdegixuhasqthiakcrhmnsyuzcmxhpvflysngyxnaahsyehqeovxtikiaxtemzchakqftitzdcpclhwbrfklrdvsui...

output:

ehxqnscholkulvstnibhqgyagucphsachchilqicqsbnyjlmsltdatnuxubastwxuoumfzoigukjsnzdqxpyqecxamcudjelouwjtwvrzpiwngpiqhsywcgpbrczqxygxjbclqmjslnhundthndtbhkbtnrdlsrhtidvouyzzxjmfhquqniddszyknhtizrxunekswyd

result:

ok single line: 'ehxqnscholkulvstnibhqgyagucphs...xjmfhquqniddszyknhtizrxunekswyd'

Test #18:

score: 90
Accepted
time: 31ms
memory: 5992kb

input:

1 1000000000
u
200000
0 1 1
0 1 1
0 1 3
0 1 0
1 2 1
0 1 0
1 5 1
1 3 3
5 11 5
4 9 15
2 7 10
26 28 27
12 15 16
1 25 0
21 42 37
52 75 66
52 55 100
23 57 80
41 43 99
43 93 128
33 155 66
61 104 143
162 187 239
179 354 191
428 433 303
14 124 365
50 266 120
335 596 809
83 578 393
916 1329 887
1618 1808 905...

output:

u

result:

ok single line: 'u'

Test #19:

score: 90
Accepted
time: 35ms
memory: 5996kb

input:

2 1000000000
dt
200000
1 2 1
0 1 3
1 3 1
0 6 0
3 6 8
2 6 7
14 15 18
12 17 10
13 23 10
2 6 8
1 33 15
31 45 58
24 44 63
41 56 75
61 94 0
77 98 58
19 68 83
51 145 78
162 180 94
36 96 257
314 329 393
93 297 75
283 557 282
113 706 765
547 1371 1178
1432 1990 1240
96 1734 1804
888 2309 4026
2429 5366 3859...

output:

tt

result:

ok single line: 'tt'

Test #20:

score: 90
Accepted
time: 31ms
memory: 6016kb

input:

3 1000000000
mik
200000
1 3 1
0 1 4
0 1 6
1 2 1
4 5 1
2 3 2
2 10 1
11 16 11
6 20 18
10 14 25
3 31 36
6 39 47
22 93 48
33 42 128
8 176 88
76 271 46
11 135 130
32 590 264
941 1051 1018
231 1175 784
1919 1947 867
77 699 685
1083 2273 1985
1428 2260 3177
3942 4778 1413
1785 4233 2889
6393 7816 6947
2365...

output:

iii

result:

ok single line: 'iii'

Test #21:

score: 90
Accepted
time: 33ms
memory: 5940kb

input:

14 1000000000
dzjdvybcfbwygq
200000
11 14 7
7 11 9
16 19 6
14 17 2
9 23 14
0 20 41
9 55 10
38 43 76
10 49 14
2 114 2
75 217 155
239 338 11
193 207 191
449 460 500
217 329 336
140 480 412
359 969 865
557 816 1358
179 953 958
472 2062 1470
2500 2545 1818
1875 3276 451
4100 4986 1031
1920 2392 4924
162...

output:

yyzycwbgqdcyyy

result:

ok single line: 'yyzycwbgqdcyyy'

Test #22:

score: 90
Accepted
time: 35ms
memory: 5936kb

input:

28 1000000000
mospjhqqnnmftgjinaopvwlrxemm
200000
5 20 14
19 31 43
31 44 9
23 42 2
34 77 29
29 30 112
17 49 110
122 158 17
72 123 152
38 215 94
115 224 29
64 468 105
88 122 251
791 819 86
198 483 89
141 338 639
1089 1155 132
552 1475 863
1278 2007 2240
1930 2886 1163
353 1258 3762
2523 4713 4323
227...

output:

orvqhaelamiqggmphgtnmjjentfa

result:

ok single line: 'orvqhaelamiqggmphgtnmjjentfa'

Test #23:

score: 90
Accepted
time: 42ms
memory: 5924kb

input:

42 1000000000
vdrptyxcpnqiaguiwuydxzahticrznztzvnxbqvfdw
200000
36 38 25
9 42 16
1 56 27
39 76 69
4 166 25
106 199 42
18 139 398
12 434 122
114 607 909
726 1110 187
104 616 484
1141 2198 1713
2196 2472 1578
1558 2167 1358
136 4163 699
2104 6376 128
2158 10747 12571
1252 13542 11708
24883 27961 20367...

output:

fdctnzzadiggdbrxvnnqdgzxanxqbuigyhxnxqabzn

result:

ok single line: 'fdctnzzadiggdbrxvnnqdgzxanxqbuigyhxnxqabzn'

Test #24:

score: 90
Accepted
time: 46ms
memory: 5936kb

input:

67 1000000000
esabhhmqxzgpnwdgzmendgfjayafxuamzysblabehdbkktaogzpsintpphqsopjjntw
200000
24 41 43
32 70 57
93 98 103
48 119 8
16 106 141
52 240 184
209 376 307
123 508 525
75 564 958
901 1015 965
173 852 1107
971 1542 1530
266 980 2057
202 1216 3429
28 128 2104
2691 3864 1470
890 3340 309
3599 7759 ...

output:

nzggnkyohaahebhnayydakeaziazasapazdpsmtiwywabahpboxfbzmgaaefmlhbbza

result:

ok single line: 'nzggnkyohaahebhnayydakeaziazas...smtiwywabahpboxfbzmgaaefmlhbbza'

Test #25:

score: 90
Accepted
time: 55ms
memory: 5936kb

input:

133 1000000000
efixmmmupbprhzqjyxrkjkbhpkyyrapmqkuplsbdytuxqwuyhwzlbedpszhxjlmztqfhnllbsyuqfthnjqwnajihqernbztvebpeezpoamxwfygrppsczehnvmqcirhkqczcf
200000
14 57 33
24 78 111
84 162 219
90 106 98
236 295 316
196 316 56
277 464 471
113 171 560
482 584 178
320 652 208
202 855 903
59 745 803
54 84 1099...

output:

xyetkhtweaubayhlwudwhbfmvuymybuhfqerhtepepzqmqibmodpyyqwydhcpqymeqpqkqmptlexqmkktqrqpwehctfrupxdnwduayqtnwyunnqwfmuzwndbabpadjdusxrqv

result:

ok single line: 'xyetkhtweaubayhlwudwhbfmvuymyb...qtnwyunnqwfmuzwndbabpadjdusxrqv'

Test #26:

score: 90
Accepted
time: 65ms
memory: 5940kb

input:

200 1000000000
putvahdaxzfocfpjrffenrunaqmijpydmxfdjktmgsxurfuaeqliviqpaqqnopkprszcoerotqzstitqquqdlrsgoehhajhzmqxsbdmznqsohwjvkusqjesldaamyyzczkjrtsninxmovypikfnzssmlsluebibkgciuzzcsdwunkzhfialbbphapceftrcixwxnlofm
200000
89 117 163
58 206 67
284 335 162
85 220 301
286 398 403
66 155 627
8 264 24
6...

output:

vxjarzsyidzhzpqskiswyshlnegefaceqtsszqppqlvzmgzusjxsyzshxucmjxnrkzskyrsaavoohequzmacyklwxskutqqltxiesqflskbuekhbilnnzhogsqzarvfnshspkwjnyssornqukmdlizziedjeocsvkxolvniozshibnfkmajdjxdoqoqnokjosharcvei

result:

ok single line: 'vxjarzsyidzhzpqskiswyshlnegefa...shibnfkmajdjxdoqoqnokjosharcvei'

Extra Test:

score: 0
Extra Test Passed