/**
 * This function calculates the correct exposure settings for a photograph.
 *
 * @param aperture The aperture value used for the photograph.
 * @param shutterSpeed The shutter speed value used for the photograph.
 * @param iso The ISO value used for the photograph.
 * @return A message with the recommended exposure settings.
 */
fun calculateExposure(aperture: Double, shutterSpeed: Double, iso: Double): String {

    // Calculate the maximum aperture value
    val maxAperture = 1 / Math.sqrt(2.0)

    // Calculate the maximum shutter speed value
    val maxShutterSpeed = 30.0

    // Calculate the maximum ISO value
    val maxIso = 3200.0

    // Check if any of the input values exceed the maximum allowed value
    if (aperture >= maxAperture || shutterSpeed >= maxShutterSpeed || iso >= maxIso) {
        return "Please adjust the input values to ensure they are within acceptable limits."
    }

    // Evaluate the precedence of logical operators and determine the exposure settings
    if (aperture < maxAperture && (shutterSpeed * iso) > 2) {
        return "Use a wider aperture, lower shutter speed, or lower ISO value for a properly exposed photograph."
    }

    return ""
}
/**
 * This function calculates the correct exposure settings for a photograph.
 *
 * @param aperture The aperture value used for the photograph.
 * @param shutterSpeed The shutter speed value used for the photograph.
 * @param iso The ISO value used for the photograph.
 * @return A message with the recommended exposure settings.
 */
fun calculateExposure(aperture: Double, shutterSpeed: Double, iso: Double): String {
/**
 * This function calculates the correct exposure settings for a photograph.
 *
 * @param aperture The aperture value used for the photograph.
 * @param shutterSpeed The shutter speed value used for the photograph.
 * @param iso The ISO value used for the photograph.
 * @return A message with the recommended exposure settings.
 */
fun calculateExposure(aperture: Double, shutterSpeed: Double, iso: Double): String {

    // Calculate the maximum aperture value
    val maxAperture = 1 / Math.sqrt(2.0)

    // Calculate the maximum shutter speed value
    val maxShutterSpeed = 30.0

    // Calculate the maximum ISO value
    val maxIso = 3200.0

    // Check if any of the input values exceed the maximum allowed value
    if (aperture >= maxAperture || shutterSpeed >= maxShutterSpeed || iso >= maxIso) {
        return "Please adjust the input values to ensure they are within acceptable limits."
    }

    // Evaluate the precedence of logical operators and determine the exposure settings
    if (aperture < maxAperture && (shutterSpeed * iso) > 2) {
        return "Use a wider aperture, lower shutter speed, or lower ISO value for a properly exposed photograph."
    }

    return ""
}