We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
I appreciate your tip about using StringBuilder to splat out the result.
On that builder part, it might be better to make two append calls rather that use + to put on the "\n". Also, you might just use string compare to compare the case where the strings are of equal length.
Still, fast overall result it looks like.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Big Sorting
You are viewing a single comment's thread. Return to all comments →
I appreciate your tip about using StringBuilder to splat out the result.
On that builder part, it might be better to make two append calls rather that use + to put on the "\n". Also, you might just use string compare to compare the case where the strings are of equal length.
Still, fast overall result it looks like.