Mathematica, 25 24 bytes
MatchQ[{{_,2}..}]@*Tally
The Tally
function returns a list of the form {{element, count}, ...}
, which is then matched against a pattern that checks whether all count are 2.
MatchQ[{{_,2}..}]@*Tally
The Tally
function returns a list of the form {{element, count}, ...}
, which is then matched against a pattern that checks whether all count are 2.