/**
 * Given a list of floating-point numbers, update each element by multiplying it with its index
 * and return the modified list.
 *
 * @param data A list of floating-point numbers
 * @return Modified list with each element multiplied by its index
 */
fun updateFloatValues(data: MutableList<Float>): List<Float> {

    // Iterate over the list using the built-in withIndex function
    for ((index, value) in data.withIndex()) {
        // Multiply each element by its index
        data[index] = value * index
    }
    
    return data
}
/**
 * Given a list of floating-point numbers, update each element by multiplying it with its index
 * and return the modified list.
 *
 * @param data A list of floating-point numbers
 * @return Modified list with each element multiplied by its index
 */
fun updateFloatValues(data: MutableList<Float>): List<Float> {
/**
 * Given a list of floating-point numbers, update each element by multiplying it with its index
 * and return the modified list.
 *
 * @param data A list of floating-point numbers
 * @return Modified list with each element multiplied by its index
 */
fun updateFloatValues(data: MutableList<Float>): List<Float> {

    // Iterate over the list using the built-in withIndex function
    for ((index, value) in data.withIndex()) {
        // Multiply each element by its index
        data[index] = value * index
    }
    
    return data
}