"John","100.00","200.00"
How to read the content of text file and then print string under quotes.
The output should be Jhon 100.00 200.00
String CUSTOMER, CURRENT, NEW;
Scanner sc = new Scanner(str);
sc.useDelimiter(",");
while(sc.hasNext()){
CUSTOMER = sc.next();
CURRENT = sc.next();
NEW = sc.next();
System.out.println("" + CUSTOMER + " " + CURRENT +
" " + NEW);
}
sc.close();
How to separate the tokens from quotes. output for above code which I am getting is this "Jhon" "100.00" "200.00"