For longest common prefix - https://leetcode.com/problems/longest-common-prefix/ , I came up with below solution which works -
https://leetcode.com/problems/longest-common-prefix/discuss/985222/Easy-Python
Can anyone tell If I am doing O(K^2) or O(Nlogn) + O(K) . If I do while loop and then list comprehension does it become O(N^2) ?