As we cannot iterate over stack, how to achieve this in min time complexity? I just got confused with this problem statement. I don't need full source code for this...Can anyone give some idea to implement this? Expected is O(N) as per problem statement....