在我的应用程序中我得到了0.00在编辑text.next时,当我输入2or3或任何数字它得到concat 0.00和0.003。添加字符串作为整数
if(item.equals("0.00")){
item=item+string;}
我改变了code.but这个时间太长了得到一个错误
if(item.equals("0.00")){
int a=Integer.parseInt(item.toString());
int b=Integer.parseInt(string.toString());
int c=a+b;
item=String.valueOf(c);}
你能提供更多的细节?你想达到什么目的?什么是确切的问题? – sandrstar