strtoll
函数在 C++ 中用于将字符串转换为长整型(long long
)数值
strtoll
将返回该整数。long long
类型范围的整数,strtoll
将返回 LLONG_MAX
(对于正数)或 LLONG_MIN
(对于负数),并设置 errno
为 ERANGE
。strtoll
将返回 0,并设置 errno
为 EINVAL
。注意:在使用 strtoll
时,请确保包含 <cstdlib>
头文件。
亿速云「云服务器」,即开即用、新一代英特尔至强铂金CPU、三副本存储NVMe SSD云盘,价格低至29元/月。点击查看>>
推荐阅读:C++中strchr函数返回值是什么