Am I wrong? Also, I am not able to understand how it is going for a TLE.
1 Like
Can u plz help me out for which case i m getting wrong answer
https://www.codechef.com/viewsolution/40933381
Yeah, you are right it is the same question. Thank you!
Check your Output for this test case 66 50000000
Your O/P is: 'zzwvutrponmgdcaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'
(This sums up to 75165824 which is wrong)
And my O/P is:
uuuuuutuuuuutttuuuuuuuuutttttttuuuuuuuuuuuuuuoruttmhnttttttptttttt
(This one sums up to 5e7)
Here is my code in Python using Heap.