The sorting activity would be a choking hazard for younger children.
As a former teacher and mother, I dislike forms of discipline that force kids to read or write as a punishment. I have seen this approach squash the spark for learning and turn kids off to school. Not a good thing.
I prefer natural consequences or ones that are some how related to the offense. Loss of privileges is also an effective discipline tool with our kids.