johnnysuperhero
New Member
- Joined
- Sep 15, 2006
- Messages
- 1
I saw the forum on the Mod 10 check digit and attempted to alter the formula to fit my needs, but yeah...I'm not the brightest bulb on the tree. Plus my numbers are 38 bytes long, which can cause some problems.
For this Mod 10 check digit, for those not familiar, you follow a multiplication sequence beginning with the last digit. The last is multiplied by two, the next is by one, the next is by two, then one, then two, and so on until you're at the first digit. (2x1x2x1x2x1x2)
When you come across a digit that will provide a 2 digit answer (ie a 9 would give an answer of 18) you need to separate the two digits and add them together. (2x9 = 18 = 1+8 = 9)
You then need to add up all of your new digits, divide the total by 10, and subtract the remainder from 10 to get the coveted check digit that I'm after. (67 / 10 = 6 r7 = 10 - 7 = check digit of 3)
I appreciate any help on this one guys. Thanks!
For this Mod 10 check digit, for those not familiar, you follow a multiplication sequence beginning with the last digit. The last is multiplied by two, the next is by one, the next is by two, then one, then two, and so on until you're at the first digit. (2x1x2x1x2x1x2)
When you come across a digit that will provide a 2 digit answer (ie a 9 would give an answer of 18) you need to separate the two digits and add them together. (2x9 = 18 = 1+8 = 9)
You then need to add up all of your new digits, divide the total by 10, and subtract the remainder from 10 to get the coveted check digit that I'm after. (67 / 10 = 6 r7 = 10 - 7 = check digit of 3)
I appreciate any help on this one guys. Thanks!