📄 test_htuu.cc
字号:
#include <string>#include <url/htuu_string.hh>#include <iterator>int main(int, char **) { vector<char> decoded; for(unsigned int i=0; i<256; ++i) decoded.push_back(i); string encoded; htuu_encode(decoded.begin,decoded.end(),back_insert_iterator<string>(encoded)); cout << "encoded: " << encoded << endl;/* vector<char> decoded_again=htuu_decode(encoded); if(decoded_again.size()!=decoded.size() { cout << "sizes do not match" << endl; return 1; } for(unsigned int i=0; i<256; ++i) if(decoded_again[i]!=decode[i]) { cout << "character " << i << " did not survive" << endl; } */ return 0; }
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -