Contains Duplicate - LeetCode 217 - Python Problem #2

Given an integer array nums, return true if any value appears at least twice in the array, and return false if every element is distinct.
Code: github.com/abhishekmshr956/Le...
LinkedIn: / abhishekmishraiitkgp
Twitter: / abhishek_iitkgp
0:00 Problem statement
1:10 O(n^2) brute force solution
4:38 O(nlogn) solution using sorting
9:41 O(n) hash set

Пікірлер: 2

  • @skandkumar9756
    @skandkumar975610 ай бұрын

    Sir what is your profession?

  • @AbhishekMishraiitkgp

    @AbhishekMishraiitkgp

    10 ай бұрын

    Postdoctoral Scientist