Hello ranchers, my assignment said "Any attempt to lock a resource that is already locked
should cause the current
thread to give up the CPU" but the lock() method in DB interface said "the current thread gives up the CPU and consumes no CPU cycles until the record is unlocked". On one hand, because it says "should" I don't have to do it. On the other hand, as it is listed in the face, I have to do it.
So my question is: of course we have to implement the interface methods, but do we
have to conform to the behavior described in the comment of the methods? Does anyone who passed the exam and didn't implement this behavior?
Thank you.