How Do Vending Machines Detect Fake Coins?

This machine can decipher coins with pinpoint accuracy. Light sensors measure the size while electromagnets detect the metal type of the coin.