An armed gang killed at least 34 people in attacks on villages in northwest Nigeria, police said on Sunday, part of a wave of violence the government has blamed on bandits.