Skip to content
This repository has been archived by the owner on Jan 5, 2018. It is now read-only.

Commit

Permalink
Initial commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
matiaskorhonen committed Sep 3, 2010
0 parents commit 7896150
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
Radix62
=======

Convert integers to base 62 strings and back.

## Installation

Just like any other gem:

gem install radix62

## Usage

Two methods are provided, Radix62#encode62 and Radix62#decode62

require "radix62"
Radix62.encode62(1000) #=> "g8"
Radix62.encode62(9999999) #=> "FXsj"
Radix62.decode62("a") #=> "10"
Radix62.decode62("A") #=> "36"
Radix62.decode62("Abc123") #=> "33146185555"
Radix62.decode62(Radix62.encode62(1234567890)) #=> 1234567890

## License and copyright

Copyright (c) 2010 Matias Korhonen

Licensed under the MIT license, see the LICENSE file for details.

0 comments on commit 7896150

Please sign in to comment.