[Codility/Swift] lesson 3 : TapeEquilibrium
Task description
Notice : N is an integer within the range 2 ~ 100,000
(Time complexity should not be O(N^2))
Solution
I tried several times and finally got an O(N) solution.
First attempt
I used the reduce function inside the for loop, result...
studio-pendant.hashnode.dev2 min read