Check out example codes for "how to check type of primitive value in java". It will help you in understanding the concepts better.

Code Example 1

int i = 20;
float f = 20.2f;
System.out.println(((Object)i).getClass().getName());
System.out.println(((Object)f).getClass().getName());

Learn ReactJs, React Native from akashmittal.com