GithubHelp home page GithubHelp logo

med-hachoum / solve-caesar Goto Github PK

View Code? Open in Web Editor NEW

This project forked from emadaismael/solve-caesar

0.0 3.0 0.0 19 KB

decrypting a caesar encrypted text with unknown shift

License: Apache License 2.0

Python 100.00%

solve-caesar's Introduction

solve-caesar

خوارزمية لكسر شيفرة قيصر

decrypting a caesar encrypted text with unknown shift

import caesar_kit


# message : CAESAR SHIFTED CIPHER TEXT
encrypted_text = '''
gb zl ynjlre :
V’z qvibeprq. Fubhyq V fryy zl rk-jvsr’f $10X qvnzbaq evat gb ohl n qbt ?
V unir pbzr bhg ng na naahny ybff bs $5,000.00 gb $10,000.00 orpnhfr V unccra gb fcraq zber zbarl ba zl qbtf naq arire urfvgngr gb ohl gurz gur irel orfg..

'''

# Use .Break method to Decrypt CAESAR SHIFTED CIPHER TEXT
decrypt = caesar_kit.Break( encrypted_text )

# print decrypted plain text 
print ( decrypt )


# use .cipher_dict() to get Cipher dictionary
print ( decrypt.cipher_dict() )

Encrypting :

import caesar_kit


# message : your text
message = '''
It so good that you are trying to find such communities around.
 This can help you interact with the people of same interests and hence find more opportunities around.
  I am not aware of any Facebook groups, but rather I think there are sites where you can go and find such groups in sites like hacker rank, code chef, hacker earth, code school and so on.
 Maybe u can google about them and you might find some mailing list or IRC channels where you could find such group of people .
'''

# Use .Encrypt method to encrypt message text , 16 is the shift key
encrypt = caesar_kit.Encrypt( message , 16 )

# print encrypted plain text 
print ( encrypt )


# use .cipher_dict() to get Cipher dictionary
print ( encrypt.cipher_dict() )

solve-caesar's People

Contributors

med-hachoum avatar emadaismael avatar

Watchers

James Cloos avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.