#Diclaimer, it was the first of four exercides it was supposed to be really simple

1 messages · Page 1 of 1 (latest)

magic jackal
earnest wagon
#

Are you sure it was o(1) though?

#

It could be like taking a bit longer with large numbers or something if it's python

#

Hard to say without seeing the code

magic jackal
#

Yeah, I am pretty sure it was O(1)

It was the first exercise, so it was simply implementing local cache with functions Get, Set and Delete, I did this using maps in golang

#

the further exercises looked more difficult, so this first one was not supposed to throw errors

#

now I'm afraid the recruiter simply don't care and reject me 😅

earnest wagon
#

Hash map collision might happen right

#

Worst case is still linear time

#

If I'm not mistaken