Created
December 6, 2016 15:09
-
-
Save d0uji/1688a09937a5dd2fc15e3f0ee2530d7c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "base64.h" | |
#include <iostream> | |
#include <windows.h> | |
int main() { | |
const std::string s = "Димас - ананас"; | |
SetConsoleOutputCP(1251); | |
std::string encoded = base64_encode(reinterpret_cast<const unsigned char*>(s.c_str()), s.length()); | |
std::string decoded = base64_decode(encoded); | |
std::cout << "encoded: " << encoded << std::endl; | |
std::cout << "decoded: " << decoded << std::endl; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment