Button Sequence question

PaulS point is interesting: There are commercial door entry units out there that check the code automatically after the correct count is entered, not requiring a 'enter' button (usually A or B)- fine! - However they then bubble the code up the array and pop the new number in at the bottom. The code is checked again!

thus:
code 1234
user enters 91234752 and gains entry, whereas we would expect the buffer to hold 4752 and fail! (door access usually lasts 7 sec)

This strange behaviour is then compounded by timing-out after n wrong tries (without a visual warning, although a grunt is issued on a fail, lamp-change for success). The next user hits the pad with the correct code and is already bared, so they start going through all the codes they have ever used, anywhere, lottery numbers, granny's birthday etc. The unit comes back on line and hey presto, locks them out again!

Point being, ensure the keypad is helpful and your users understand what it is trying to tell them.