public class test {
public static void main(String[] args) {
int total = 2;
int rn = 1;
double rnp = (rn / total) * 100;
System.out.println(rnp);
}
}
なぜ50.0ではなく0.0を出力するのですか?
https://www.google.com/search?q=100*(1%2F2)&aq=f&oq=100*(1%2F2)