You are viewing a single comment's thread. Return to all comments →
Your code is extremely inefficient, it only looks short. You are using three loops when you require only 1. The complexity of your solution is O(3n)
Seems like cookies are disabled on this browser, please enable them to open this website
Plus Minus
You are viewing a single comment's thread. Return to all comments →
Your code is extremely inefficient, it only looks short. You are using three loops when you require only 1. The complexity of your solution is O(3n)