Given two arrays of equal length, y_true and y_pred, return the classification accuracy as a floating-point value. Accuracy is defined as the number of matching labels divided by the total number of labels. If the input arrays have different lengths or are empty, return 0.0.
def calculate_accuracy(y_true, y_pred):