Prior to inserting the key, the pins inside the lock are arranged in a random manner and each pin is composed of 2 parts, the top part known as the driver pin, and the bottom part known as the key pin [7]. As can be seen in the image, the length of each part varies, meaning that no 2 parts are the same measurement. However, all pins are the same length and as of now, the lock is locked [7].
Each set of keys is designed uniquely in order to unlock its designated lock. As you insert the key in the plug, the rigids on the key push the pins upwards [7]. Each rigid on the key is designed for a key pin, that way, when you insert the key, the key pins will move upwards according to the rigid on the key, pushing the springs upwards as well [7]. The reason the springs in the lock are crucial is because they cause a downwards force as the driver pins push up on them [7]. This will assure that the pins are applying some force on the key so that no issue arises as you try to unlock the lock. When they key is fully inserted, all the bottom parts (in red) will align to form a straight line [7].
After the bottom parts of the pins form a straight line, the key is rotated, and the lock is unlocked [7]. The reason you have to rotate the key in order to unlock the lock is because the top and the bottom part of the pin are magnets held together, so when you rotate the key, the top and bottom part of the key split and that is what causes the lock to unlock [7].
Figure 11: Different Shapes of Keys
Keys are small in size and very thin as can be seen in figure 11. The reason they are small is because it makes them easy to carry around, store, and most importantly use [5]. If keys were big and bulky, then they would be hard to move and carry around. The small opening on the top of the key is made to hold different keys together [5]. As we know, each lock has a designated key, meaning that each key opens a specific lock [5]. As people carry around multiple keys at a time, the small opening on the top of the key makes it easier to keep track of all the keys and hold them together. The head of the key is usually wider than the end of the key because it makes the key easier to use [5]. It allows people to have a grip on the key as they use it, and that way it would take them a matter of seconds on unlock a lock.
[8]