Maybe I am wrong here, isn't the time complexity of second approach (optimised bf) is O(n*n*log(n)), because insertion in map is log(n) and not n? Also if we use unordered_map instead of map, won't it be O(n*n)? Btw great solution! never thought O(n) was even possible
Great Intuition
Very great explaination for observasion in optimise approach, thank you for your content❤🔥
great explanation thanks for the video :)
I think need to watch this Video Twice kal ka be thoda sa tough chala gya explanation mere liye🫡
explaination
🔥
Please explain the EDITORIAL solution with O(1) space complexity
Great video 👌🏻
Maybe I am wrong here, isn't the time complexity of second approach (optimised bf) is O(n*n*log(n)), because insertion in map is log(n) and not n? Also if we use unordered_map instead of map, won't it be O(n*n)?
Btw great solution! never thought O(n) was even possible
How did you came up with this type of solution 😐, very hard to observe
CFBR
Niceeee
🫡🫡❤️