Can somebody help me understand why I get an error message that says possible loss of precision on this program? I don't understand what could be causing this error message. When I get this error message, it highlightes the line of code that says: "theTemps[index] = inFile.next();". Can somebody enlighten me as to why I get this error message? Thanks
/**
* This program calculates the monthly Heat Index for a specific city.
*
* @author John D. Barry
* @date January 30, 2009
*/
import java.util.Scanner;
import java.io.IOException;
import java.io.PrintWriter;
import java.io.File;
class HeatIndex
{
public static void main (String [ ] args) throws IOException
{
double index = 0.0;
double [] theTemps = new double[14];
File temps = new File("KeyWestTemp.txt");
Scanner inFile = new Scanner(temps);
while (inFile.hasNext())
{
theTemps[index] = inFile.next();
}
inFile.close();
}
}