code: func extractPossibleNumber(number string) string {
  	if VALID_START_CHAR_PATTERN.MatchString(number) {
  		start := VALID_START_CHAR_PATTERN.FindIndex([]byte(number))[0]
  		number = number[start:]
  		// Remove trailing non-alpha non-numerical characters.
  		indices := UNWANTED_END_CHAR_PATTERN.FindIndex([]byte(number))
  		if len(indices) > 0 {
  			number = number[0:indices[0]]
  		}
  		// Check for extra numbers at the end.
  		indices = SECOND_NUMBER_START_PATTERN.FindIndex([]byte(number))
  		if len(indices) > 0 {
  			number = number[0:indices[0]]
  		}
  		return number
  	}
  	return ""
  }
docs: // Attempts to extract a possible number from the string passed in.
  // This currently strips all leading characters that cannot be used to
  // start a phone number. Characters that can be used to start a phone
  // number are defined in the VALID_START_CHAR_PATTERN. If none of these
  // characters are found in the number passed in, an empty string is
  // returned. This function also attempts to strip off any alternative
  // extensions or endings if two or more are present, such as in the case
  // of: (530) 583-6985 x302/x2303. The second extension here makes this
  // actually two phone numbers, (530) 583-6985 x302 and (530) 583-6985 x2303.
  // We remove the second extension so that the first number is parsed correctly.