Skip to content

A version of the famous cipher in ruby

License

Notifications You must be signed in to change notification settings

anderojr/caesar_cipher

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Caesar's Cipher in Ruby 💎

A simple implementation of the Caesar's Cipher written in Ruby programming language.

Description

The Caesar's Cipher is one of the simplest and most widely known encryption techniques. It is a substitution cipher in which each letter in the plaintext is shifted a certain number of places down the alphabet.

Usage

To use the code, you can clone this repository and run the file v2.rb. You will start the CLI that guide you to the usage and operations possible.

Otherwise, you can just run or add the caesar_cipher.rb in your code and call the function as this:

caesar_cipher(string, shift_factor, operation)
  • string: the string you want to cipher or decipher
  • shift_factor: the number of letters you want to shift
  • operation: the operation you want to do with the string, 1 to cipher and -1 to decipher

Contributing

Feel free to contribute to this project by opening an issue or a pull request.

License

This project is licensed under the Mozilla Public License 2.0

About

A version of the famous cipher in ruby

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages