怎么样(对char c)int i = (int)(c - '0');减去char值是什么?是API问题(评论),还是扩展方法?public static class CharExtensions { public static int ParseInt32(this char value) { int i = (int)(value - '0'); if (i < 0 || i > 9) throw new ArgumentOutOfRangeException("value"); return i; }}然后使用 int x = c.ParseInt32();