@greghogg5: Merry Christmas - This Function is Big O(n).

Greg Hogg
Greg Hogg
Open In TikTok:
Region: CA
Monday 25 December 2023 13:00:00 GMT
8519
408
13
6

Music

Download

Comments

user3738392827383
user3738392827383 :
I know it’s not about solving it, but can’t you do this len(set(nums)) != len(nums)
2023-12-25 13:40:14
6
fartbocks64
O(n^n) :
You could just use a hashmap since accessing a hashmap is O(1) if you did map[num] +=1 and then if map[num] > 1 return true you would have O(n)
2023-12-25 16:32:54
0
georgepanaiotov
George Panaiotov :
num in h is O(n) also, so it still is O(n²)
2023-12-25 13:15:55
2
wallzjon_12
Jon :
👍
2023-12-25 20:43:14
0
greghogg5
Greg Hogg :
I offer 1 on 1 tutoring for Data Structures & Algorithms! Email me at [email protected] - first call is free!
2024-01-04 20:06:15
0
0ovoido0
Ѵ🌀ID :
why are u not using the greenscreen thats already there...
2023-12-25 16:41:15
0
jerry_echimau
Jerry :
as a Christmas gift, could you be my mentor in this complicated Tech Journey 😁
2023-12-25 14:49:31
0
To see more videos from user @greghogg5, please go to the Tikwm homepage.

Other Videos


About