simplified if total statement