cpp/openlocationcode.cc
// Compute the latitude precision value for a given code length. Lengths <= 10
// have the same precision for latitude and longitude, but lengths > 10 have
// different precisions due to the grid method having fewer columns than rows.
Compute the latitude precision value for a given code length. Lengths <= 10
have the same precision for latitude and longitude, but lengths > 10 have
different precisions due to the grid method having fewer columns than rows.
Compute the latitude precision value for a given code length . Lengths < = 10 have the same precision for latitude and longitude but lengths > 10 have different precisions due to the grid method having fewer columns than rows .
double compute_precision_for_length(int code_length) {
  if (code_length <= 10) {
    return pow_neg(internal::kEncodingBase, floor((code_length / -2) + 2));
  }
  return pow_neg(internal::kEncodingBase, -3) / pow(5, code_length - 10);
}
double compute_precision_for_length ( int code_length ) { if ( code_length <= 10 ) { return pow_neg ( internal :: kEncodingBase , floor ( ( code_length / -2 ) + 2 ) ) ; } return pow_neg ( internal :: kEncodingBase , -3 ) / pow ( 5 , code_length - 10 ) ; }
Compute the latitude precision value for a given code length.
Compute the latitude precision value for a given code length .