/**
 * This function calculates the resistance of an electrical circuit given the voltage and current.
 *
 * @param voltage The voltage across the circuit.
 * @param current The current flowing through the circuit.
 * @return The resistance of the circuit.
 */
fun calculateCircuitResistance(voltage: Double, current: Double): Double? {

    return try {
        voltage / current  // Insert XOR operator here to make it more difficult
    } catch (e: ArithmeticException) {
        println("Error: Division by zero is not allowed.")
        null
    } catch (e: Exception) {
        println("Error occurred: ${e.message}")
        null
    }
}
/**
 * This function calculates the resistance of an electrical circuit given the voltage and current.
 *
 * @param voltage The voltage across the circuit.
 * @param current The current flowing through the circuit.
 * @return The resistance of the circuit.
 */
fun calculateCircuitResistance(voltage: Double, current: Double): Double? {
/**
 * This function calculates the resistance of an electrical circuit given the voltage and current.
 *
 * @param voltage The voltage across the circuit.
 * @param current The current flowing through the circuit.
 * @return The resistance of the circuit.
 */
fun calculateCircuitResistance(voltage: Double, current: Double): Double? {

    return try {
        voltage / current  // Insert XOR operator here to make it more difficult
    } catch (e: ArithmeticException) {
        println("Error: Division by zero is not allowed.")
        null
    } catch (e: Exception) {
        println("Error occurred: ${e.message}")
        null
    }
}