I first introduce propositional functions that will be useful in the definition:

IntegerQ[(2012/4)]

Not[IntegerQ[(2012/100)]]

IntegerQ[(Y/400)]

Now I put them together to teach Mathematica which years are leap years

LeapQ[Y_] := 
      Or[
And[IntegerQ[(Y/4)], 
          Not[IntegerQ[(Y/100)]]], 
IntegerQ[
          (Y/400)]]

LeapQ[2012]

LeapQ[2013]

LeapQ[2100]

An equivalent way of defining this function is

LeapQ1[Y_] := 
And[
        IntegerQ[(Y/4)], 
Or[Not[IntegerQ[(Y/100)]], 
          IntegerQ[(Y/400)]]]

LeapQ1[2012]

LeapQ1[2000]

LeapQ1[2100]

LeapQ1[2013]