if "11" & "4" are output pins, you can not use in this place. Those should be input or the boolean variable where you can store input/output/constant values.
if ( 11 == HIGH && 4 == HIGH && dly<= 500 )
Note: better assign name for each and every pin and use in code.