fixed overflow for normalization of score