fn format_significant_digits(f: f64, digits: usize) -> String
Format a double value to a specified number of significant digits.