No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

main.cpp 589B

12345678910111213141516171819
  1. #include <iostream>
  2. #include "include/Crypt.h"
  3. const char START = 'a';
  4. const char END = 'z';
  5. /**
  6. @brief Take a string on command line argument to encrypt it. For vigenere encnyption, the text is encrypted with itself as a key
  7. **/
  8. int main( int argc, char* argv[] )
  9. {
  10. std::string txt = argv[1] ;
  11. std::cout << "to encrypt :" << txt << std::endl;
  12. std::cout << "code cesar :" << Crypt::cesar(txt, 3 ) << std::endl ;
  13. std::cout << "code vigenere :" << Crypt::vigenere(txt, txt ) << std::endl ;
  14. std::cout << "code atbash :" << Crypt::atbash( txt ) << std::endl ;
  15. return 0;
  16. }