Arrays.sort(arr) is also working , there is no restriction to use merge sort only, we can solve by direct method or any other sort.
Arrays.sort(arr) is also working
That’s not the point. You should learn merge sort to build logic and it has its own advantages. Besides, by same logic you should not learn what heap is, since it is already implemented in every language.
I know , merger has own advantage , but there is no restriction to use only merger sort, please add this feature, and when i can expect it will be added?
I’m pretty sure it won’t be added any soon. Because the point of giving out a question is to learn to code something new, not merely gain a few points. And if you don’t wish to code for such problems wherein you can get the entire solution using a built in library, it’s very well up to you.
And just to point out something, you’ll learn that Arrays.sort isn’t that good once you start coding on Codeforces
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.