/**
 * Given gene expression levels for two genes, determine if gene1 has higher or lower expression than gene2.
 *
 * @param gene1 Gene expression level for gene 1.
 * @param gene2 Gene expression level for gene 2.
 * @return A message indicating the relative expression levels of the genes.
 * @throws IllegalArgumentException If gene expression levels are not provided or are of incorrect data type.
 */
fun compareGeneExpression(gene1: Double, gene2: Double): String {

    if (gene1 !is Double || gene2 !is Double) {
        throw IllegalArgumentException("Gene expression levels must be provided as floating-point values.")
    }

    return when {
        gene1 > gene2 -> "Gene 1 has higher expression than Gene 2."
        gene2 > gene1 -> "Gene 2 has higher expression than Gene 1."
        else -> "Both genes have equal expression levels."
    }
}
/**
 * Given gene expression levels for two genes, determine if gene1 has higher or lower expression than gene2.
 *
 * @param gene1 Gene expression level for gene 1.
 * @param gene2 Gene expression level for gene 2.
 * @return A message indicating the relative expression levels of the genes.
 * @throws IllegalArgumentException If gene expression levels are not provided or are of incorrect data type.
 */
fun compareGeneExpression(gene1: Double, gene2: Double): String {
/**
 * Given gene expression levels for two genes, determine if gene1 has higher or lower expression than gene2.
 *
 * @param gene1 Gene expression level for gene 1.
 * @param gene2 Gene expression level for gene 2.
 * @return A message indicating the relative expression levels of the genes.
 * @throws IllegalArgumentException If gene expression levels are not provided or are of incorrect data type.
 */
fun compareGeneExpression(gene1: Double, gene2: Double): String {

    if (gene1 !is Double || gene2 !is Double) {
        throw IllegalArgumentException("Gene expression levels must be provided as floating-point values.")
    }

    return when {
        gene1 > gene2 -> "Gene 1 has higher expression than Gene 2."
        gene2 > gene1 -> "Gene 2 has higher expression than Gene 1."
        else -> "Both genes have equal expression levels."
    }
}