A 16-year-old Massachusetts boy has pleaded guilty to computer hacking and will serve 11 months in a juvenile detention center.