StringBuilder到String返回空字符串

以下输出为空字符串。我试图找出原因,但是我做不到,有人可以帮忙吗?

StringBuilder sb = new StringBuilder();
sb.append("1").append(",");
String s = sb.substring(0,1);
System.out.println("Extracted String is "+s);
评论