需要支持C11
#include <iostream>
#include <sstream>
std::string hexValue = "0FCC7877180097";
std::istringstream converter{ hexValue };
long long value = 0;
converter >> std::hex >> value;
C++ 16进制字符串转long long
阅读 92
2022-03-25
需要支持C11
#include <iostream>
#include <sstream>
std::string hexValue = "0FCC7877180097";
std::istringstream converter{ hexValue };
long long value = 0;
converter >> std::hex >> value;
相关推荐
精彩评论(0)