aochoae/checkdigit-algorithms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Quality Gate Status

Algorithms:

  • Damm algorithm
  • Luhn algorithm
  • Verhoeff algorithm

Documentation

We need to create a Java file to contain the following code:

package demo;

import io..aochoae.checkdigit.LuhnCheckDigit;

public class App {

    public static void main(String args[]) {

        LuhnCheckDigit checkDigit = new LuhnCheckDigit();

        System.out.println(checkDigit.generate("4872148"));

    }
}

The output must be

48721484

Add the following dependency to your project:

dependencies {
    implementation 'io..aochoae:checkdigit-algorithms:2.1.2'
}
<dependencies>
    <dependency>
        <groupId>io..aochoae</groupId>
        <artifactId>checkdigit-algorithms</artifactId>
        <version>2.1.2</version>
    </dependency>
</dependencies>

Copyright 2020- Luis A. Ochoa

This project is licensed under the Apache License, Version 2.0. See LICENSE for the full license text.

About

Damm, Luhn and Verhoeff algorithms

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages