Check out example codes for "java get int from double without rounding". It will help you in understanding the concepts better.

Code Example 1

int value = (int) 6.14; // 6 
int score = (int) 6.99; // 6

Learn ReactJs, React Native from akashmittal.com