Quantum Key Distribution solves the major bottleneck of symmetric key cryptography, the key distribution. As the name suggests, it uses laws of quantum mechanics to its advantage. I will discuss the mathematics behind the simple qubit (quantum bit) version and extend it to qudits (quantum d-bits). I will briefly touch upon how we realise such a system in our lab.