Q1: Change validate_m to validate and multiply_m to multiply to run the code
Q2: The script performs matrix multiplication. It reads number of rows and cols. Verifies the rule for matrix multiplication and conducts matrix multiplcation of two input matrices.
Q3: If condition in validate() function verifies if the input provided for rows and cols valiables not null and within the range of 0 to 9. If this logic doesn't match it prints invalid dimenions. It also checks of the $rows are not zero and $cols are not zero. Thus it doesn't accept empty matrices as input.
Q4: if conduction that checks number of arguments passed runs first. if [ $# -ne 2 ];