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.
Using 2 loops is not overcomplicating. Overcomplicating is your "code". I would be angry for my emloyee if he writes such code like yours. Looking at 2 loops everybody gets in mere second what is going on. Looking at your code one needs to waste much more time figuring out what is going on there.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Left Rotation
You are viewing a single comment's thread. Return to all comments →
Using 2 loops is not overcomplicating. Overcomplicating is your "code". I would be angry for my emloyee if he writes such code like yours. Looking at 2 loops everybody gets in mere second what is going on. Looking at your code one needs to waste much more time figuring out what is going on there.