Hello,
please I have a java code that reads from file. I want to use while loop to pick each character at a time into an array for further computation but I get this message 'incomparable types: char and String'. what does it mean?
please I have a java code that reads from file. I want to use while loop to pick each character at a time into an array for further computation but I get this message 'incomparable types: char and String'. what does it mean?
Code:
[
for (int i = 0; i < bFile.length; i++) {
System.out.print((char)bFile[i]);
}
System.out.println("Done");
}catch(Exception e){
e.printStackTrace();
}
while (((char)bFile[i])!="") ....//here gives the error
{
}
]
Comment