Click here to Skip to main content
Click here to Skip to main content

Calculating CheckSum using LUHN Algorithm

By , 26 Feb 2008
 

Introduction

What the article/code snippet does, why it's useful, the problem it solves etc.

Background

(Optional) Is there any background to this article that may be useful such as an introduction to the basic ideas presented?

Using the code

A brief description of how to use the article or code. The class names, the methods and properties, any tricks or tips.

Blocks of code should be set as style "Formatted" like this:

			//
			// Any source code blocks look like this
			//
		

Remember to set the Language of your code snippet using the Language dropdown.

Use the "var" button to to wrap Variable or class names in <code> tags like this.

Points of Interest

Did you learn anything interesting/fun/annoying while writing the code? Did you do anything particularly clever or wild or zany?

History

Keep a running update of any changes or improvements you've made here.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

About the Author

iymo2000
Unknown
Member
No Biography provided

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
QuestionIncorrect check digitmemberJPhelps12 Nov '08 - 1:20 
hi there,
 
I had a look at this and whilst it does appear as a nice test program the check digit is typically one value to high.
 
Can you check this please? Im open to correction if i am wrong but it does appear that the values generated are incorrect.
 
E.g. try this:
892700000079916805 - check digit should be 5 so we have 892700000079916805(5)
but instead this is generated in your app as: 892700000079916805(3)

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web03 | 2.6.130523.1 | Last Updated 26 Feb 2008
Article Copyright 2008 by iymo2000
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid