Validate your Credit / Debit Card’s Number

0
437

This is a fun thing to know: All credit and debit card numbers conform to a mathematical formula. Yes, they are not random!

Surprised? Test it out now:

  1. Take out your debit or credit card and write down all the digits in its number (in order) on a piece of paper
  2. Starting with the second-last digit, double every alternate digit (moving from right to left) and replace the original digit with the sum of the digits of its doubled value
  3. Add up all the resultant digits
  4. If the sum is a multiple of 10, then the card number is valid. Otherwise its not.

Example

Step 1: Card number: 4 0 1 2  8 8 8 8  8 8 8 8  1 8 8 1

Step 2: Double every alternate digit: (see digits in bold for changes)

= (8)  0  (2)  2  (16)  8  (16)  8  (16)  8  (16)  8  (2)  8  (16) 1
= (8)  0  (2)  2  (1 + 6)  8  (1 + 6)  8  (1 + 6)  8  (1 + 6)   8  (2)  8  (1 + 6)  1
= 8  0   2  7  8   8   8   8   8   1

Step 3: Add up the resulting digits:

8 + 0 + 2 + 2 + 7 + 8 + 7 + 8 + 7 + 8 + 7 + 8 + 2 + 8 + 7 + 1 = 90

Step 4: 90 is a multiple of 10. So yes, this is a valid card number