how to remove everything after 1 decimal place in java code example Example: java format double no decimal places int x = (int) y