I have two questions :
1. I know that the data type "byte" occupied 1 bytes in memory,and the value range is form -127 to +128.The data type "short" occupied 4 bytes in memory,and the value range is form -(2 to the power 31) to +(2 to the power 31)...etc.
Data type "float" occupied 4 bytes in memory,but its' value range is not from -(2 to the power 31) to +(2 to the power 31).It's from -3.4E38 to -1.4E45 in negative value and from 1.4E45 to 3.4E38 in positive value,because use scientific notation.
Although I have already know why the "float" range value is different form "int" is because scientific notation.But I can't imagine how to calculate the "float" value range.
2.Java has two kinds of variables,one is member variable,another is local variable.And the member variable is divide into two parts : static rariable and instance variable.One different from member variable and local variable is that member variable be initialized automatically and the local raviable is not.But how to distinguish member variable and local variable in program? Or how to distinguish static variable and instance variable?
Thanks for your answer.
