I presume the idea is imported from the USA. I recall cycling past proper prison work parties in Louisiana - with guys in orange jump suits, guards on horseback with stetsons and pump action shotguns...
There are huffy kids out litter-picking at other places too, complete with orange bibs and less well armed supervisors. Does it work? Obviously yes, as the USA is almost crime free.