Obama to town wracked by school shooting: 'These tragedies must end'