The compiler is saying that if you assign a double like 9.5 to an int variable you will lose the 0.5 part because the int variable will hold 9.
If that is what you want to happen, then use a cast to...
Type: Posts; User: Norm
The compiler is saying that if you assign a double like 9.5 to an int variable you will lose the 0.5 part because the int variable will hold 9.
If that is what you want to happen, then use a cast to...
Look at the Double class for a method to parse decimal numbers. The Integer class's parseInt() method is for integer/whole numbers (digits only)