EricR / caesar.rb

A simple implementation of the Caesar cipher in 22 lines of Ruby. Just for fun.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

A simple implementation of the Caesar cipher in 22 lines of Ruby.

puts Ceasar.encipher(72,"HELLO WORLD! THIS IS AN ENCRYPTED MESSAGE.") # => "BYFFI QILFX! NBCM CM UH YHWSJNYX GYMMUAY."
puts Ceasar.decipher(72,"BYFFI QILFX! NBCM CM UH YHWSJNYX GYMMUAY.") # => "HELLO WORLD! THIS IS AN ENCRYPTED MESSAGE."

To install:

gem install Caesar.rb

About

A simple implementation of the Caesar cipher in 22 lines of Ruby. Just for fun.


Languages

Language:Ruby 100.0%