This question has already been answered:
double i = 100 / 3; float j = 100 / 3; System.out.println(i); System.out.println(j); Returns: 33.0
Why not 33.3?
This question has already been answered:
double i = 100 / 3; float j = 100 / 3; System.out.println(i); System.out.println(j); Returns: 33.0
Why not 33.3?
A similar question was asked earlier and an answer has already been received. If the answers provided are not exhaustive, please ask a new question .
Source: https://ru.stackoverflow.com/questions/748095/
All Articles
double i = 100 / 3.0;. - kot-da-vinci