I think you have forgotten the basic rule of logical arguments, you HAVE to test EACH argument for the condition individually, UNLESS the condition itself resolves to zero/not zero, so maybe this:
Formula: copy to clipboard
=IF(AND(SUM(E6:E7)=K3,SUM(E9:E13)=K3,SUM(E15:E16)=K3,SUM(E18:E19)=K3,SUM(E21:E22)=K3),K3,"Check")


Hope this helps