Can you till me what is missing in my Code
DemonLord1 (0)

import java.util.Scanner;//did not work
import java.io.File;
import java.io.FileNotFoundException;
import java.io.PrintStream;

public class ReadAndWrite {

public static void main(String [] args) 
		throws FileNotFoundException {
	
	Scanner diskScanner = new Scanner(new File("rawData.txt"));
	
	PrintStream diskWriter = new PrintStream("vita.txt");
	double unitPrice, quantity,total;
	
	unitPrice = diskScanner.nextDouble();
	quantity = diskScanner.nextInt();
	
	total = unitPrice * quantity;
	diskWriter.println(total);
	
	diskScanner.close();
	diskWriter.close();
		
}

}

You are viewing a single comment. View All