Computer Language/유니티

자료형(실수)

알 수 없는 사용자 2014. 3. 31. 09:45

void Start () {

Debug.Log("float Min = " + float.MinValue + ", Max = " + float.MaxValue);

Debug.Log ("double Min = " + double.MaxValue + ", Max = " + double.MaxValue);

Debug.Log ("decimial Min = " + decimal.MaxValue + ",Max = " + decimal.MaxValue);

}


decimal 돈 계산시 사용, 29자리. 속도가 느리다

float double 계산이 정확하지 않음. 그나마 더블이 정확한데 오차가 많다.