0461.cpp (112B)
1 class Solution { 2 public: 3 int hammingDistance(unsigned x, unsigned y) const { return popcount(x ^ y); } 4 };