Modified PrintResult function to allow for Nullable<int> result input to allow swapping between AdvancedMatrix and Matrix