Taking matters into his own hands, an Australian boy solved a schoolyard whodunit using his wits and a clever invention.

Harry Cordaiy, 11, was one of many students in his class who were tired of having their lunch money stolen by unknown thieves. After teachers failed to take action, Cordaiy rigged a mousetrap and used a $5 bill as bait, the Sydney Morning Herald reported Sunday.

"I decided to act because I was annoyed that they had robbed a lot of classes, and a lot of people were missing $20," Cordaiy told the Herald.

Click here for the Sydney Morning Herald story.

Cordaiy applied green food coloring on the mousetrap’s bar and metal fittings and cut a small hole in the money, securing it on the bait hook with sticky tape, so the thief would be hit with the colored bar while stealing the money, the Herald reported.

Cordaiy, who spends hours watching the History Channel, placed the mousetrap in his backpack while at recess.

One of the thieves was caught green-handed while rushing to the bathroom in a desperate attempt to wash off the evidence. Another peer was also nabbed.