I have a CSV file which displays a name followed by 3 integers as shown below.
"John","12","37","1000"
I have the 3 number values indexed as values[1], values[2] and values[3].
I am trying to parse the strings from the CSV file by using the following:
int wins = Integer.parseInt(values[1]);
int losses = Integer.parseInt(values[2]);
int money = Integer.parseInt(values[3]);
My problem is that the values in the CSV file already are surrounded by " ", so when I try to parse the string it is trying to parse ""12"", ""37"" and ""1000"".
Is there any way in which I could ignore the " " in the CSV file without deleting them manually in the file?