如何把char转成int

来源:互联网 发布:iphone4s可以用4g网络 编辑:程序博客网 时间:2024/05/16 08:08

char型是数字字符,

int sum = str.charAt(0)-48;

0 0
原创粉丝点击