/**
 * This function takes two lists as input and modifies the elements of the first list
 * based on the values from the second list using nested loops.
 *
 * @param list1 A list of biomedical data.
 * @param list2 A list of values to modify the elements of list1.
 *
 * @return None
 *
 * Example:
 * modifyListNestedLoops(listOf(1, 2, 3, 4, 5), listOf(10, 20, 30, 40, 50))
 * After executing the function, list1 is modified as [11, 22, 33, 44, 55].
 */
fun modifyListNestedLoops(list1: MutableList<Int>, list2: List<Int>) {

    // Iterate over each element in list1
    for (i in list1.indices) {
        // Iterate over each element in list2
        for (j in list2.indices) {
            // Modify the element in list1 based on the value in list2
            list1[i] += list2[j]
        }
    }
    
    println(list1)
}
/**
 * This function takes two lists as input and modifies the elements of the first list
 * based on the values from the second list using nested loops.
 *
 * @param list1 A list of biomedical data.
 * @param list2 A list of values to modify the elements of list1.
 *
 * @return None
 *
 * Example:
 * modifyListNestedLoops(listOf(1, 2, 3, 4, 5), listOf(10, 20, 30, 40, 50))
 * After executing the function, list1 is modified as [11, 22, 33, 44, 55].
 */
fun modifyListNestedLoops(list1: MutableList<Int>, list2: List<Int>) {
/**
 * This function takes two lists as input and modifies the elements of the first list
 * based on the values from the second list using nested loops.
 *
 * @param list1 A list of biomedical data.
 * @param list2 A list of values to modify the elements of list1.
 *
 * @return None
 *
 * Example:
 * modifyListNestedLoops(listOf(1, 2, 3, 4, 5), listOf(10, 20, 30, 40, 50))
 * After executing the function, list1 is modified as [11, 22, 33, 44, 55].
 */
fun modifyListNestedLoops(list1: MutableList<Int>, list2: List<Int>) {

    // Iterate over each element in list1
    for (i in list1.indices) {
        // Iterate over each element in list2
        for (j in list2.indices) {
            // Modify the element in list1 based on the value in list2
            list1[i] += list2[j]
        }
    }
    
    println(list1)
}