Sorry, if I am not posting my try. I have no idea how to approach this.
I want charArr to be converted to doubleVal:
char[] charArr = {'1'','1','.','1','1','1'};
double doubleVal = 11.11;
Sorry, if I am not posting my try. I have no idea how to approach this.
I want charArr to be converted to doubleVal:
char[] charArr = {'1'','1','.','1','1','1'};
double doubleVal = 11.11;
here is a hint
Something like this:
StringBuilder sb = new StringBuilder();
sb.append(charArr);
Double d = Double.parseDouble(sb.toString());
Something like that: you can try this
for(int i=0; i<charArr.length;i++){
char c =charArr[i];
Double d = Double.parseDouble(c.toString());
// do some operation
}