/**
 * This function takes in two dictionaries, 'aerospaceData" and 'accelerometerData`,
 * and returns a list of common keys between the two dictionaries.
 *
 * @param aerospaceData A dictionary containing data related to aerospace engineering.
 * @param accelerometerData A dictionary containing data from an accelerometer.
 * @return A list of common keys between the two dictionaries.
 *
 * Example:
 * Given the following dictionaries:
 * val aerospaceData = mapOf("aircraft" to "Boeing 747", "launch_vehicle" to "Falcon Heavy", "satellite" to "Hubble")
 * val accelerometerData = mapOf("aircraft" to "Airbus A320", "testing_rig" to "XYZ-123", "sensor" to "XYZ-ABC")
 *
 * The function should return:
 * ['aircraft']
 */
fun findCommonKeys(aerospaceData: Map<String, String>, accelerometerData: Map<String, String>): List<String> {

    val commonKeys = mutableListOf<String>()

    // Looping through the keys of aerospaceData
    for (key in aerospaceData.keys) {
        // Checking if the key exists in accelerometerData
        if (key in accelerometerData.keys) {
            // Appending the common key to the commonKeys list
            commonKeys.add(key)
        }
    }

    return commonKeys
}
/**
 * This function takes in two dictionaries, 'aerospaceData" and 'accelerometerData`,
 * and returns a list of common keys between the two dictionaries.
 *
 * @param aerospaceData A dictionary containing data related to aerospace engineering.
 * @param accelerometerData A dictionary containing data from an accelerometer.
 * @return A list of common keys between the two dictionaries.
 *
 * Example:
 * Given the following dictionaries:
 * val aerospaceData = mapOf("aircraft" to "Boeing 747", "launch_vehicle" to "Falcon Heavy", "satellite" to "Hubble")
 * val accelerometerData = mapOf("aircraft" to "Airbus A320", "testing_rig" to "XYZ-123", "sensor" to "XYZ-ABC")
 *
 * The function should return:
 * ['aircraft']
 */
fun findCommonKeys(aerospaceData: Map<String, String>, accelerometerData: Map<String, String>): List<String> {
/**
 * This function takes in two dictionaries, 'aerospaceData" and 'accelerometerData`,
 * and returns a list of common keys between the two dictionaries.
 *
 * @param aerospaceData A dictionary containing data related to aerospace engineering.
 * @param accelerometerData A dictionary containing data from an accelerometer.
 * @return A list of common keys between the two dictionaries.
 *
 * Example:
 * Given the following dictionaries:
 * val aerospaceData = mapOf("aircraft" to "Boeing 747", "launch_vehicle" to "Falcon Heavy", "satellite" to "Hubble")
 * val accelerometerData = mapOf("aircraft" to "Airbus A320", "testing_rig" to "XYZ-123", "sensor" to "XYZ-ABC")
 *
 * The function should return:
 * ['aircraft']
 */
fun findCommonKeys(aerospaceData: Map<String, String>, accelerometerData: Map<String, String>): List<String> {

    val commonKeys = mutableListOf<String>()

    // Looping through the keys of aerospaceData
    for (key in aerospaceData.keys) {
        // Checking if the key exists in accelerometerData
        if (key in accelerometerData.keys) {
            // Appending the common key to the commonKeys list
            commonKeys.add(key)
        }
    }

    return commonKeys
}