verhoeff

Version, currently 1.0.12 versions

github.com/Crystal-Matter/verhoeff

implementation of the Verhoeff checksum algorithm in crystal lang

0 stars
1 dependent
License: MIT

Installation

# Add this to your shard.yml
dependencies:
  verhoeff:
    github: Crystal-Matter/verhoeff
    version: ~> 1.0.1

Then run:

shards install

shard.yml

Crystal
no constraint declared
License
MIT
Author
Stephen von Takach

Dependencies

Development Dependencies

  • ameba*github: veelenga/amebadev

README

verhoeff

An implementation of the verhoeff algorithm for crystal lang

Installation

  1. Add the dependency to your shard.yml:

    dependencies:
      verhoeff:
        github: spider-gazelle/verhoeff
  2. Run shards install

Usage

require "verhoeff"

puts Verhoeff.generate_checksum(1234)  # => 0
puts Verhoeff.validate(12340)          # => true

puts Verhoeff.generate_checksum("1234")  # => 0
puts Verhoeff.validate("12340")          # => true

Contributors